diff options
Diffstat (limited to 'src/testcurl/test_digestauth_emu_ext.c')
-rw-r--r-- | src/testcurl/test_digestauth_emu_ext.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/testcurl/test_digestauth_emu_ext.c b/src/testcurl/test_digestauth_emu_ext.c index 10e04477..e10944c7 100644 --- a/src/testcurl/test_digestauth_emu_ext.c +++ b/src/testcurl/test_digestauth_emu_ext.c | |||
@@ -599,7 +599,7 @@ ahc_echo (void *cls, | |||
599 | 599 | ||
600 | 600 | ||
601 | static CURL * | 601 | static CURL * |
602 | setupCURL (void *cbc, int port) | 602 | setupCURL (void *cbc, uint16_t port) |
603 | { | 603 | { |
604 | CURL *c; | 604 | CURL *c; |
605 | char url[512]; | 605 | char url[512]; |
@@ -610,7 +610,8 @@ setupCURL (void *cbc, int port) | |||
610 | /* A workaround for some old libcurl versions, which ignore the specified | 610 | /* A workaround for some old libcurl versions, which ignore the specified |
611 | * port by CURLOPT_PORT when authorisation is used. */ | 611 | * port by CURLOPT_PORT when authorisation is used. */ |
612 | res = snprintf (url, (sizeof(url) / sizeof(url[0])), | 612 | res = snprintf (url, (sizeof(url) / sizeof(url[0])), |
613 | "http://127.0.0.1:%d%s", port, MHD_URI_BASE_PATH); | 613 | "http://127.0.0.1:%u%s", |
614 | (unsigned int) port, MHD_URI_BASE_PATH); | ||
614 | if ((0 >= res) || ((sizeof(url) / sizeof(url[0])) <= (size_t) res)) | 615 | if ((0 >= res) || ((sizeof(url) / sizeof(url[0])) <= (size_t) res)) |
615 | externalErrorExitDesc ("Cannot form request URL"); | 616 | externalErrorExitDesc ("Cannot form request URL"); |
616 | } | 617 | } |