Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
708af6d9
Commit
708af6d9
authored
Jun 24, 2014
by
Sergey Lyubka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more comments in big_upload.c
parent
e4c71425
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
big_upload.c
examples/big_upload.c
+4
-4
No files found.
examples/big_upload.c
View file @
708af6d9
...
@@ -29,7 +29,7 @@ static int handle_request(struct mg_connection *conn) {
...
@@ -29,7 +29,7 @@ static int handle_request(struct mg_connection *conn) {
conn
->
connection_param
=
p
;
conn
->
connection_param
=
p
;
mg_send_header
(
conn
,
"Content-Type"
,
"text/html"
);
mg_send_header
(
conn
,
"Content-Type"
,
"text/html"
);
}
}
return
MG_MORE
;
return
MG_MORE
;
// Tell mongoose to keep this connection open
}
else
{
}
else
{
mg_printf_data
(
conn
,
"%s"
,
mg_printf_data
(
conn
,
"%s"
,
"<html><body>Upload example."
"<html><body>Upload example."
...
@@ -38,7 +38,7 @@ static int handle_request(struct mg_connection *conn) {
...
@@ -38,7 +38,7 @@ static int handle_request(struct mg_connection *conn) {
"<input type=
\"
file
\"
name=
\"
file
\"
/> <br/>"
"<input type=
\"
file
\"
name=
\"
file
\"
/> <br/>"
"<input type=
\"
submit
\"
value=
\"
Upload
\"
/>"
"<input type=
\"
submit
\"
value=
\"
Upload
\"
/>"
"</form></body></html>"
);
"</form></body></html>"
);
return
MG_TRUE
;
return
MG_TRUE
;
// Tell mongoose to close this connection
}
}
}
}
...
@@ -59,10 +59,10 @@ static int handle_poll(struct mg_connection *conn) {
...
@@ -59,10 +59,10 @@ static int handle_poll(struct mg_connection *conn) {
fclose
(
p
->
fp
);
fclose
(
p
->
fp
);
free
(
p
);
free
(
p
);
conn
->
connection_param
=
NULL
;
conn
->
connection_param
=
NULL
;
return
MG_TRUE
;
return
MG_TRUE
;
// Tell mongoose to close this connection
}
}
}
}
return
MG_FALSE
;
return
MG_FALSE
;
// Tell mongoose to keep this connection open
}
}
static
int
ev_handler
(
struct
mg_connection
*
conn
,
enum
mg_event
ev
)
{
static
int
ev_handler
(
struct
mg_connection
*
conn
,
enum
mg_event
ev
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment