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
4927195e
Commit
4927195e
authored
Mar 08, 2016
by
Alexander Alashkin
Committed by
Marko Mikulicic
Mar 10, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use mongoose event to free updater resources
PUBLISHED_FROM=3044287fe2623b591ddbf5c619398c21d6753411
parent
63be1ebd
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
mongoose.c
mongoose.c
+3
-2
mongoose.h
mongoose.h
+3
-3
No files found.
mongoose.c
View file @
4927195e
...
...
@@ -5072,15 +5072,16 @@ void mg_http_handler(struct mg_connection *nc, int ev, void *ev_data) {
*/
struct
mg_http_stream_info
si
;
struct
mg_http_multipart_part
mp
;
mg_event_handler_t
handler
;
memset
(
&
mp
,
0
,
sizeof
(
mp
));
mg_http_parse_stream_info
(
&
pd
->
strm_state
,
&
si
);
handler
=
mg_http_get_endpoint_handler
(
nc
->
listener
,
&
si
.
endpoint
);
mp
.
status
=
-
1
;
mp
.
var_name
=
si
.
var_name
.
p
;
mp
.
file_name
=
si
.
file_name
.
p
;
mg_call
(
nc
,
pd
->
endpoint_handler
?
pd
->
endpoint_handler
:
nc
->
handler
,
MG_EV_HTTP_PART_END
,
&
mp
);
mg_call
(
nc
,
(
handler
?
handler
:
nc
->
handler
),
MG_EV_HTTP_PART_END
,
&
mp
);
}
else
#endif
if
(
io
->
len
>
0
&&
mg_parse_http
(
io
->
buf
,
io
->
len
,
hm
,
is_req
)
>
0
)
{
...
...
mongoose.h
View file @
4927195e
...
...
@@ -134,8 +134,10 @@
#endif
#include <assert.h>
#include <direct.h>
#include <errno.h>
#include <fcntl.h>
#include <io.h>
#include <limits.h>
#include <signal.h>
#include <stddef.h>
...
...
@@ -143,8 +145,6 @@
#include <stdlib.h>
#include <sys/stat.h>
#include <time.h>
#include <direct.h>
#include <io.h>
#define random() rand()
#ifdef _MSC_VER
...
...
@@ -839,7 +839,7 @@ const char *c_strnstr(const char *s, const char *find, size_t slen);
!(defined(_POSIX_C_SOURCE) && _POSIX_C_SOURCE >= 200809L) && \
!(defined(__DARWIN_C_LEVEL) && __DARWIN_C_LEVEL >= 200809L) && \
!defined(RTOS_SDK)) && \
!(defined(_MSC_VER) && _MSC_VER >= 1600
/* MSVC2013
+ has strnlen */
)
!(defined(_MSC_VER) && _MSC_VER >= 1600
/* MSVC2010
+ has strnlen */
)
#define _MG_PROVIDE_STRNLEN
size_t
strnlen
(
const
char
*
s
,
size_t
maxlen
);
#endif
...
...
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