diff options
Diffstat (limited to 'src/microhttpd/internal.c')
-rw-r--r-- | src/microhttpd/internal.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/microhttpd/internal.c b/src/microhttpd/internal.c index d2532c54..8e9e0aac 100644 --- a/src/microhttpd/internal.c +++ b/src/microhttpd/internal.c | |||
@@ -162,7 +162,7 @@ MHD_http_unescape (char *val) | |||
162 | } | 162 | } |
163 | } | 163 | } |
164 | *wpos = '\0'; /* add 0-terminator */ | 164 | *wpos = '\0'; /* add 0-terminator */ |
165 | return wpos - val; /* = strlen(val) */ | 165 | return wpos - val; |
166 | } | 166 | } |
167 | 167 | ||
168 | 168 | ||
@@ -190,6 +190,7 @@ MHD_parse_arguments_ (struct MHD_Connection *connection, | |||
190 | struct MHD_Daemon *daemon = connection->daemon; | 190 | struct MHD_Daemon *daemon = connection->daemon; |
191 | char *equals; | 191 | char *equals; |
192 | char *amper; | 192 | char *amper; |
193 | size_t len; | ||
193 | 194 | ||
194 | *num_headers = 0; | 195 | *num_headers = 0; |
195 | while ( (NULL != args) && | 196 | while ( (NULL != args) && |
@@ -210,6 +211,7 @@ MHD_parse_arguments_ (struct MHD_Connection *connection, | |||
210 | if (MHD_YES != cb (connection, | 211 | if (MHD_YES != cb (connection, |
211 | args, | 212 | args, |
212 | NULL, | 213 | NULL, |
214 | 0, | ||
213 | kind)) | 215 | kind)) |
214 | return MHD_NO; | 216 | return MHD_NO; |
215 | (*num_headers)++; | 217 | (*num_headers)++; |
@@ -223,12 +225,13 @@ MHD_parse_arguments_ (struct MHD_Connection *connection, | |||
223 | connection, | 225 | connection, |
224 | args); | 226 | args); |
225 | MHD_unescape_plus (equals); | 227 | MHD_unescape_plus (equals); |
226 | daemon->unescape_callback (daemon->unescape_callback_cls, | 228 | len = daemon->unescape_callback (daemon->unescape_callback_cls, |
227 | connection, | 229 | connection, |
228 | equals); | 230 | equals); |
229 | if (MHD_YES != cb (connection, | 231 | if (MHD_YES != cb (connection, |
230 | args, | 232 | args, |
231 | equals, | 233 | equals, |
234 | len, | ||
232 | kind)) | 235 | kind)) |
233 | return MHD_NO; | 236 | return MHD_NO; |
234 | (*num_headers)++; | 237 | (*num_headers)++; |
@@ -248,6 +251,7 @@ MHD_parse_arguments_ (struct MHD_Connection *connection, | |||
248 | if (MHD_YES != cb (connection, | 251 | if (MHD_YES != cb (connection, |
249 | args, | 252 | args, |
250 | NULL, | 253 | NULL, |
254 | 0, | ||
251 | kind)) | 255 | kind)) |
252 | return MHD_NO; | 256 | return MHD_NO; |
253 | /* continue with 'bar' */ | 257 | /* continue with 'bar' */ |
@@ -264,12 +268,13 @@ MHD_parse_arguments_ (struct MHD_Connection *connection, | |||
264 | connection, | 268 | connection, |
265 | args); | 269 | args); |
266 | MHD_unescape_plus (equals); | 270 | MHD_unescape_plus (equals); |
267 | daemon->unescape_callback (daemon->unescape_callback_cls, | 271 | len = daemon->unescape_callback (daemon->unescape_callback_cls, |
268 | connection, | 272 | connection, |
269 | equals); | 273 | equals); |
270 | if (MHD_YES != cb (connection, | 274 | if (MHD_YES != cb (connection, |
271 | args, | 275 | args, |
272 | equals, | 276 | equals, |
277 | len, | ||
273 | kind)) | 278 | kind)) |
274 | return MHD_NO; | 279 | return MHD_NO; |
275 | (*num_headers)++; | 280 | (*num_headers)++; |