aboutsummaryrefslogtreecommitdiff
path: root/src/testcurl/test_timeout.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testcurl/test_timeout.c')
-rw-r--r--src/testcurl/test_timeout.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/testcurl/test_timeout.c b/src/testcurl/test_timeout.c
index 404cf040..79f8c88d 100644
--- a/src/testcurl/test_timeout.c
+++ b/src/testcurl/test_timeout.c
@@ -149,8 +149,8 @@ termination_cb (void *cls,
149static size_t 149static size_t
150putBuffer (void *stream, size_t size, size_t nmemb, void *ptr) 150putBuffer (void *stream, size_t size, size_t nmemb, void *ptr)
151{ 151{
152 unsigned int *pos = ptr; 152 size_t *pos = ptr;
153 unsigned int wrt; 153 size_t wrt;
154 154
155 wrt = size * nmemb; 155 wrt = size * nmemb;
156 if (wrt > 8 - (*pos)) 156 if (wrt > 8 - (*pos))
@@ -223,17 +223,17 @@ ahc_echo (void *cls,
223} 223}
224 224
225 225
226static int 226static unsigned int
227testWithoutTimeout (void) 227testWithoutTimeout (void)
228{ 228{
229 struct MHD_Daemon *d; 229 struct MHD_Daemon *d;
230 CURL *c; 230 CURL *c;
231 char buf[2048]; 231 char buf[2048];
232 struct CBC cbc; 232 struct CBC cbc;
233 unsigned int pos = 0; 233 size_t pos = 0;
234 int done_flag = 0; 234 int done_flag = 0;
235 CURLcode errornum; 235 CURLcode errornum;
236 int port; 236 uint16_t port;
237 237
238 if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) 238 if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT))
239 port = 0; 239 port = 0;
@@ -264,7 +264,7 @@ testWithoutTimeout (void)
264 { 264 {
265 MHD_stop_daemon (d); return 32; 265 MHD_stop_daemon (d); return 32;
266 } 266 }
267 port = (int) dinfo->port; 267 port = dinfo->port;
268 } 268 }
269 c = curl_easy_init (); 269 c = curl_easy_init ();
270 curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1/hello_world"); 270 curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1/hello_world");
@@ -310,7 +310,7 @@ testWithoutTimeout (void)
310} 310}
311 311
312 312
313static int 313static unsigned int
314testWithTimeout (void) 314testWithTimeout (void)
315{ 315{
316 struct MHD_Daemon *d; 316 struct MHD_Daemon *d;
@@ -319,7 +319,7 @@ testWithTimeout (void)
319 struct CBC cbc; 319 struct CBC cbc;
320 int done_flag = 0; 320 int done_flag = 0;
321 CURLcode errornum; 321 CURLcode errornum;
322 int port; 322 uint16_t port;
323 323
324 if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) 324 if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT))
325 port = 0; 325 port = 0;
@@ -350,7 +350,7 @@ testWithTimeout (void)
350 { 350 {
351 MHD_stop_daemon (d); return 32; 351 MHD_stop_daemon (d); return 32;
352 } 352 }
353 port = (int) dinfo->port; 353 port = dinfo->port;
354 } 354 }
355 c = curl_easy_init (); 355 c = curl_easy_init ();
356 curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1/hello_world"); 356 curl_easy_setopt (c, CURLOPT_URL, "http://127.0.0.1/hello_world");