aboutsummaryrefslogtreecommitdiff
path: root/src/microhttpd/test_postprocessor.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/microhttpd/test_postprocessor.c')
-rw-r--r--src/microhttpd/test_postprocessor.c31
1 files changed, 17 insertions, 14 deletions
diff --git a/src/microhttpd/test_postprocessor.c b/src/microhttpd/test_postprocessor.c
index 029600a2..8edc5b22 100644
--- a/src/microhttpd/test_postprocessor.c
+++ b/src/microhttpd/test_postprocessor.c
@@ -91,6 +91,8 @@ value_checker (void *cls,
91{ 91{
92 int *want_off = cls; 92 int *want_off = cls;
93 int idx = *want_off; 93 int idx = *want_off;
94 (void)kind; /* Unused. Silent compiler warning. */
95
94 96
95#if 0 97#if 0
96 fprintf (stderr, 98 fprintf (stderr,
@@ -120,14 +122,14 @@ value_checker (void *cls,
120 122
121 123
122static int 124static int
123test_urlencoding () 125test_urlencoding (void)
124{ 126{
125 struct MHD_Connection connection; 127 struct MHD_Connection connection;
126 struct MHD_HTTP_Header header; 128 struct MHD_HTTP_Header header;
127 struct MHD_PostProcessor *pp; 129 struct MHD_PostProcessor *pp;
128 unsigned int want_off = URL_START; 130 unsigned int want_off = URL_START;
129 int i; 131 size_t i;
130 int delta; 132 size_t delta;
131 size_t size; 133 size_t size;
132 134
133 memset (&connection, 0, sizeof (struct MHD_Connection)); 135 memset (&connection, 0, sizeof (struct MHD_Connection));
@@ -154,7 +156,7 @@ test_urlencoding ()
154 156
155 157
156static int 158static int
157test_multipart_garbage () 159test_multipart_garbage (void)
158{ 160{
159 struct MHD_Connection connection; 161 struct MHD_Connection connection;
160 struct MHD_HTTP_Header header; 162 struct MHD_HTTP_Header header;
@@ -195,7 +197,7 @@ test_multipart_garbage ()
195 197
196 198
197static int 199static int
198test_multipart_splits () 200test_multipart_splits (void)
199{ 201{
200 struct MHD_Connection connection; 202 struct MHD_Connection connection;
201 struct MHD_HTTP_Header header; 203 struct MHD_HTTP_Header header;
@@ -228,14 +230,14 @@ test_multipart_splits ()
228 230
229 231
230static int 232static int
231test_multipart () 233test_multipart (void)
232{ 234{
233 struct MHD_Connection connection; 235 struct MHD_Connection connection;
234 struct MHD_HTTP_Header header; 236 struct MHD_HTTP_Header header;
235 struct MHD_PostProcessor *pp; 237 struct MHD_PostProcessor *pp;
236 unsigned int want_off = FORM_START; 238 unsigned int want_off = FORM_START;
237 int i; 239 size_t i;
238 int delta; 240 size_t delta;
239 size_t size; 241 size_t size;
240 242
241 memset (&connection, 0, sizeof (struct MHD_Connection)); 243 memset (&connection, 0, sizeof (struct MHD_Connection));
@@ -263,14 +265,14 @@ test_multipart ()
263 265
264 266
265static int 267static int
266test_nested_multipart () 268test_nested_multipart (void)
267{ 269{
268 struct MHD_Connection connection; 270 struct MHD_Connection connection;
269 struct MHD_HTTP_Header header; 271 struct MHD_HTTP_Header header;
270 struct MHD_PostProcessor *pp; 272 struct MHD_PostProcessor *pp;
271 unsigned int want_off = FORM_NESTED_START; 273 unsigned int want_off = FORM_NESTED_START;
272 int i; 274 size_t i;
273 int delta; 275 size_t delta;
274 size_t size; 276 size_t size;
275 277
276 memset (&connection, 0, sizeof (struct MHD_Connection)); 278 memset (&connection, 0, sizeof (struct MHD_Connection));
@@ -298,14 +300,14 @@ test_nested_multipart ()
298 300
299 301
300static int 302static int
301test_empty_value () 303test_empty_value (void)
302{ 304{
303 struct MHD_Connection connection; 305 struct MHD_Connection connection;
304 struct MHD_HTTP_Header header; 306 struct MHD_HTTP_Header header;
305 struct MHD_PostProcessor *pp; 307 struct MHD_PostProcessor *pp;
306 unsigned int want_off = URL_EMPTY_VALUE_START; 308 unsigned int want_off = URL_EMPTY_VALUE_START;
307 int i; 309 size_t i;
308 int delta; 310 size_t delta;
309 size_t size; 311 size_t size;
310 312
311 memset (&connection, 0, sizeof (struct MHD_Connection)); 313 memset (&connection, 0, sizeof (struct MHD_Connection));
@@ -337,6 +339,7 @@ int
337main (int argc, char *const *argv) 339main (int argc, char *const *argv)
338{ 340{
339 unsigned int errorCount = 0; 341 unsigned int errorCount = 0;
342 (void)argc; (void)argv; /* Unused. Silent compiler warning. */
340 343
341 errorCount += test_multipart_splits (); 344 errorCount += test_multipart_splits ();
342 errorCount += test_multipart_garbage (); 345 errorCount += test_multipart_garbage ();