diff options
Diffstat (limited to 'src/testcurl/test_long_header.c')
-rw-r--r-- | src/testcurl/test_long_header.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/testcurl/test_long_header.c b/src/testcurl/test_long_header.c index c1d07cb3..6ed8d78d 100644 --- a/src/testcurl/test_long_header.c +++ b/src/testcurl/test_long_header.c | |||
@@ -96,7 +96,7 @@ ahc_echo (void *cls, | |||
96 | } | 96 | } |
97 | 97 | ||
98 | 98 | ||
99 | static int | 99 | static unsigned int |
100 | testLongUrlGet (size_t buff_size) | 100 | testLongUrlGet (size_t buff_size) |
101 | { | 101 | { |
102 | struct MHD_Daemon *d; | 102 | struct MHD_Daemon *d; |
@@ -105,13 +105,13 @@ testLongUrlGet (size_t buff_size) | |||
105 | struct CBC cbc; | 105 | struct CBC cbc; |
106 | char *url; | 106 | char *url; |
107 | long code; | 107 | long code; |
108 | int port; | 108 | uint16_t port; |
109 | 109 | ||
110 | if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) | 110 | if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) |
111 | port = 0; | 111 | port = 0; |
112 | else | 112 | else |
113 | { | 113 | { |
114 | port = 1330 + buff_size % 20; | 114 | port = 1330 + (uint16_t) (buff_size % 20); |
115 | if (oneone) | 115 | if (oneone) |
116 | port += 5; | 116 | port += 5; |
117 | } | 117 | } |
@@ -136,7 +136,7 @@ testLongUrlGet (size_t buff_size) | |||
136 | { | 136 | { |
137 | MHD_stop_daemon (d); return 32; | 137 | MHD_stop_daemon (d); return 32; |
138 | } | 138 | } |
139 | port = (int) dinfo->port; | 139 | port = dinfo->port; |
140 | } | 140 | } |
141 | c = curl_easy_init (); | 141 | c = curl_easy_init (); |
142 | url = malloc (VERY_LONG); | 142 | url = malloc (VERY_LONG); |
@@ -187,7 +187,7 @@ testLongUrlGet (size_t buff_size) | |||
187 | } | 187 | } |
188 | 188 | ||
189 | 189 | ||
190 | static int | 190 | static unsigned int |
191 | testLongHeaderGet (size_t buff_size) | 191 | testLongHeaderGet (size_t buff_size) |
192 | { | 192 | { |
193 | struct MHD_Daemon *d; | 193 | struct MHD_Daemon *d; |
@@ -197,13 +197,13 @@ testLongHeaderGet (size_t buff_size) | |||
197 | char *url; | 197 | char *url; |
198 | long code; | 198 | long code; |
199 | struct curl_slist *header = NULL; | 199 | struct curl_slist *header = NULL; |
200 | int port; | 200 | uint16_t port; |
201 | 201 | ||
202 | if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) | 202 | if (MHD_NO != MHD_is_feature_supported (MHD_FEATURE_AUTODETECT_BIND_PORT)) |
203 | port = 0; | 203 | port = 0; |
204 | else | 204 | else |
205 | { | 205 | { |
206 | port = 1331 + buff_size % 20; | 206 | port = 1331 + (uint16_t) (buff_size % 20); |
207 | if (oneone) | 207 | if (oneone) |
208 | port += 5; | 208 | port += 5; |
209 | } | 209 | } |
@@ -229,7 +229,7 @@ testLongHeaderGet (size_t buff_size) | |||
229 | { | 229 | { |
230 | MHD_stop_daemon (d); return 32; | 230 | MHD_stop_daemon (d); return 32; |
231 | } | 231 | } |
232 | port = (int) dinfo->port; | 232 | port = dinfo->port; |
233 | } | 233 | } |
234 | c = curl_easy_init (); | 234 | c = curl_easy_init (); |
235 | url = malloc (VERY_LONG); | 235 | url = malloc (VERY_LONG); |