aboutsummaryrefslogtreecommitdiff
path: root/tests/libtest
diff options
context:
space:
mode:
Diffstat (limited to 'tests/libtest')
-rw-r--r--tests/libtest/first.c12
-rw-r--r--tests/libtest/lib1506.c10
-rw-r--r--tests/libtest/lib1510.c6
-rw-r--r--tests/libtest/lib1512.c6
-rw-r--r--tests/libtest/lib1513.c4
-rw-r--r--tests/libtest/lib1517.c4
-rw-r--r--tests/libtest/lib1538.c7
-rw-r--r--tests/libtest/lib500.c4
-rw-r--r--tests/libtest/lib505.c4
-rw-r--r--tests/libtest/lib506.c8
-rw-r--r--tests/libtest/lib508.c4
-rw-r--r--tests/libtest/lib510.c4
-rw-r--r--tests/libtest/lib513.c4
-rw-r--r--tests/libtest/lib514.c4
-rw-r--r--tests/libtest/lib515.c4
-rw-r--r--tests/libtest/lib516.c4
-rw-r--r--tests/libtest/lib517.c4
-rw-r--r--tests/libtest/lib526.c10
-rw-r--r--tests/libtest/lib530.c8
-rw-r--r--tests/libtest/lib533.c4
-rw-r--r--tests/libtest/lib540.c8
-rw-r--r--tests/libtest/lib544.c4
-rw-r--r--tests/libtest/lib547.c4
-rw-r--r--tests/libtest/lib552.c14
-rw-r--r--tests/libtest/lib553.c8
-rw-r--r--tests/libtest/lib554.c8
-rw-r--r--tests/libtest/lib555.c6
-rw-r--r--tests/libtest/lib557.c70
-rw-r--r--tests/libtest/lib567.c4
-rw-r--r--tests/libtest/lib568.c6
-rw-r--r--tests/libtest/lib569.c4
-rw-r--r--tests/libtest/lib570.c4
-rw-r--r--tests/libtest/lib571.c4
-rw-r--r--tests/libtest/lib572.c6
-rw-r--r--tests/libtest/lib578.c4
-rw-r--r--tests/libtest/lib579.c4
-rw-r--r--tests/libtest/lib586.c10
-rw-r--r--tests/libtest/lib589.c2
-rw-r--r--tests/libtest/lib599.c4
-rw-r--r--tests/libtest/mk-lib1521.pl6
40 files changed, 148 insertions, 147 deletions
diff --git a/tests/libtest/first.c b/tests/libtest/first.c
index 72140e314..706d853ca 100644
--- a/tests/libtest/first.c
+++ b/tests/libtest/first.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -72,8 +72,8 @@ void wait_ms(int ms)
select_wrapper(0, NULL, NULL, NULL, &t);
}
-char *libtest_arg2=NULL;
-char *libtest_arg3=NULL;
+char *libtest_arg2 = NULL;
+char *libtest_arg3 = NULL;
int test_argc;
char **test_argv;
@@ -123,7 +123,7 @@ char *hexdump(const unsigned char *buffer, size_t len)
size_t i;
if(len > 200)
return NULL;
- for(i=0; i<len; i++, p += 3)
+ for(i = 0; i<len; i++, p += 3)
snprintf(p, 4, "%02x ", buffer[i]);
return dump;
}
@@ -162,10 +162,10 @@ int main(int argc, char **argv)
test_argv = argv;
if(argc>2)
- libtest_arg2=argv[2];
+ libtest_arg2 = argv[2];
if(argc>3)
- libtest_arg3=argv[3];
+ libtest_arg3 = argv[3];
URL = argv[1]; /* provide this to the rest */
diff --git a/tests/libtest/lib1506.c b/tests/libtest/lib1506.c
index 47fc335ce..687437636 100644
--- a/tests/libtest/lib1506.c
+++ b/tests/libtest/lib1506.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 2013, Linus Nielsen Feltzing <linus@haxx.se>
+ * Copyright (C) 2013, 2017, Linus Nielsen Feltzing <linus@haxx.se>
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -45,7 +45,7 @@ int test(char *URL)
(void)URL;
/* Create fake DNS entries for serverX.example.com for all handles */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
snprintf(dnsentry, sizeof(dnsentry), "server%d.example.com:%s:%s",
i + 1, port, address);
printf("%s\n", dnsentry);
@@ -66,7 +66,7 @@ int test(char *URL)
multi_setopt(m, CURLMOPT_MAXCONNECTS, 3L);
/* get NUM_HANDLES easy handles */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
/* get an easy handle */
easy_init(curl[i]);
/* specify target */
@@ -85,7 +85,7 @@ int test(char *URL)
fprintf(stderr, "Start at URL 0\n");
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
/* add handle to multi */
multi_add_handle(m, curl[i]);
@@ -123,7 +123,7 @@ test_cleanup:
/* proper cleanup sequence - type PB */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
curl_multi_remove_handle(m, curl[i]);
curl_easy_cleanup(curl[i]);
}
diff --git a/tests/libtest/lib1510.c b/tests/libtest/lib1510.c
index 25e9fed31..d72749b24 100644
--- a/tests/libtest/lib1510.c
+++ b/tests/libtest/lib1510.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 2013, Linus Nielsen Feltzing <linus@haxx.se>
+ * Copyright (C) 2013, 2017, Linus Nielsen Feltzing <linus@haxx.se>
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -43,7 +43,7 @@ int test(char *URL)
(void)URL;
/* Create fake DNS entries for serverX.example.com for all handles */
- for(i=0; i < NUM_URLS; i++) {
+ for(i = 0; i < NUM_URLS; i++) {
snprintf(dnsentry, sizeof(dnsentry), "server%d.example.com:%s:%s", i + 1,
port, address);
printf("%s\n", dnsentry);
@@ -72,7 +72,7 @@ int test(char *URL)
easy_setopt(curl, CURLOPT_MAXCONNECTS, 3L);
/* get NUM_HANDLES easy handles */
- for(i=0; i < NUM_URLS; i++) {
+ for(i = 0; i < NUM_URLS; i++) {
/* specify target */
snprintf(target_url, sizeof(target_url),
"http://server%d.example.com:%s/path/1510%04i",
diff --git a/tests/libtest/lib1512.c b/tests/libtest/lib1512.c
index f4091b45a..5e794b293 100644
--- a/tests/libtest/lib1512.c
+++ b/tests/libtest/lib1512.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 2013 - 2016, Linus Nielsen Feltzing <linus@haxx.se>
+ * Copyright (C) 2013 - 2017, Linus Nielsen Feltzing <linus@haxx.se>
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -55,7 +55,7 @@ int test(char *URL)
slist = curl_slist_append(slist, dnsentry);
/* get NUM_HANDLES easy handles */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
/* get an easy handle */
easy_init(curl[i]);
/* specify target */
@@ -76,7 +76,7 @@ int test(char *URL)
easy_setopt(curl[0], CURLOPT_RESOLVE, slist);
/* run NUM_HANDLES transfers */
- for(i=0; (i < NUM_HANDLES) && !res; i++)
+ for(i = 0; (i < NUM_HANDLES) && !res; i++)
res = curl_easy_perform(curl[i]);
test_cleanup:
diff --git a/tests/libtest/lib1513.c b/tests/libtest/lib1513.c
index d0123f1f6..932ca7208 100644
--- a/tests/libtest/lib1513.c
+++ b/tests/libtest/lib1513.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2015, 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -48,7 +48,7 @@ static int progressKiller(void *arg,
int test(char *URL)
{
CURL *curl;
- int res=0;
+ int res = 0;
global_init(CURL_GLOBAL_ALL);
diff --git a/tests/libtest/lib1517.c b/tests/libtest/lib1517.c
index e270ed74d..ea622b046 100644
--- a/tests/libtest/lib1517.c
+++ b/tests/libtest/lib1517.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -54,7 +54,7 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
struct WriteThis pooh;
diff --git a/tests/libtest/lib1538.c b/tests/libtest/lib1538.c
index e4e16f203..91481e88d 100644
--- a/tests/libtest/lib1538.c
+++ b/tests/libtest/lib1538.c
@@ -37,13 +37,14 @@ int test(char *URL)
curl_easy_strerror(-INT_MAX);
curl_multi_strerror(-INT_MAX);
curl_share_strerror(-INT_MAX);
- for(easyret=CURLE_OK; easyret <= CURL_LAST; easyret++) {
+ for(easyret = CURLE_OK; easyret <= CURL_LAST; easyret++) {
printf("e%d: %s\n", (int)easyret, curl_easy_strerror(easyret));
}
- for(multiret=CURLM_CALL_MULTI_PERFORM; multiret <= CURLM_LAST; multiret++) {
+ for(multiret = CURLM_CALL_MULTI_PERFORM; multiret <= CURLM_LAST;
+ multiret++) {
printf("m%d: %s\n", (int)multiret, curl_multi_strerror(multiret));
}
- for(shareret=CURLSHE_OK; shareret <= CURLSHE_LAST; shareret++) {
+ for(shareret = CURLSHE_OK; shareret <= CURLSHE_LAST; shareret++) {
printf("s%d: %s\n", (int)shareret, curl_share_strerror(shareret));
}
diff --git a/tests/libtest/lib500.c b/tests/libtest/lib500.c
index d17b24b20..677ab73a7 100644
--- a/tests/libtest/lib500.c
+++ b/tests/libtest/lib500.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -61,7 +61,7 @@ int test(char *URL)
{
CURLcode res;
CURL *curl;
- char *ipstr=NULL;
+ char *ipstr = NULL;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib505.c b/tests/libtest/lib505.c
index ad5d214c6..cc7463bde 100644
--- a/tests/libtest/lib505.c
+++ b/tests/libtest/lib505.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -43,7 +43,7 @@ int test(char *URL)
struct_stat file_info;
struct curl_slist *hl;
- struct curl_slist *headerlist=NULL;
+ struct curl_slist *headerlist = NULL;
const char *buf_1 = "RNFR 505";
const char *buf_2 = "RNTO 505-forreal";
diff --git a/tests/libtest/lib506.c b/tests/libtest/lib506.c
index d26252b6f..1b522be64 100644
--- a/tests/libtest/lib506.c
+++ b/tests/libtest/lib506.c
@@ -131,7 +131,7 @@ static void *fire(void *ptr)
struct curl_slist *headers;
struct Tdata *tdata = (struct Tdata*)ptr;
CURL *curl;
- int i=0;
+ int i = 0;
curl = curl_easy_init();
if(!curl) {
@@ -261,7 +261,7 @@ int test(char *URL)
res = 0;
/* start treads */
- for(i=1; i<=THREADS; i++) {
+ for(i = 1; i <= THREADS; i++) {
/* set thread data */
tdata.url = suburl(URL, i); /* must be curl_free()d */
@@ -349,7 +349,7 @@ int test(char *URL)
/* try to free share, expect to fail because share is in use*/
printf("try SHARE_CLEANUP...\n");
scode = curl_share_cleanup(share);
- if(scode==CURLSHE_OK) {
+ if(scode == CURLSHE_OK) {
fprintf(stderr, "curl_share_cleanup succeed but error expected\n");
share = NULL;
}
@@ -368,7 +368,7 @@ test_cleanup:
/* free share */
printf("SHARE_CLEANUP\n");
scode = curl_share_cleanup(share);
- if(scode!=CURLSHE_OK)
+ if(scode != CURLSHE_OK)
fprintf(stderr, "curl_share_cleanup failed, code errno %d\n",
(int)scode);
diff --git a/tests/libtest/lib508.c b/tests/libtest/lib508.c
index 1f6c6838a..30705e46a 100644
--- a/tests/libtest/lib508.c
+++ b/tests/libtest/lib508.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -50,7 +50,7 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
struct WriteThis pooh;
diff --git a/tests/libtest/lib510.c b/tests/libtest/lib510.c
index 4c290f1ef..4d568df44 100644
--- a/tests/libtest/lib510.c
+++ b/tests/libtest/lib510.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -62,7 +62,7 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
struct curl_slist *slist = NULL;
struct WriteThis pooh;
pooh.counter = 0;
diff --git a/tests/libtest/lib513.c b/tests/libtest/lib513.c
index 7c34bc4db..c6a98cca2 100644
--- a/tests/libtest/lib513.c
+++ b/tests/libtest/lib513.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -35,7 +35,7 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib514.c b/tests/libtest/lib514.c
index 7b33d52f9..702058b19 100644
--- a/tests/libtest/lib514.c
+++ b/tests/libtest/lib514.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -26,7 +26,7 @@
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib515.c b/tests/libtest/lib515.c
index 6fb178720..9f29d43c9 100644
--- a/tests/libtest/lib515.c
+++ b/tests/libtest/lib515.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -26,7 +26,7 @@
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib516.c b/tests/libtest/lib516.c
index 00c54c450..6d83e218c 100644
--- a/tests/libtest/lib516.c
+++ b/tests/libtest/lib516.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -26,7 +26,7 @@
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib517.c b/tests/libtest/lib517.c
index 22162ff1e..af7b2aa7a 100644
--- a/tests/libtest/lib517.c
+++ b/tests/libtest/lib517.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -131,7 +131,7 @@ int test(char *URL)
(void)URL; /* not used */
- for(i=0; dates[i]; i++) {
+ for(i = 0; dates[i]; i++) {
printf("%d: %s => %ld\n", i, dates[i], (long)curl_getdate(dates[i], NULL));
}
diff --git a/tests/libtest/lib526.c b/tests/libtest/lib526.c
index 522cd7422..5e41cc0a1 100644
--- a/tests/libtest/lib526.c
+++ b/tests/libtest/lib526.c
@@ -59,7 +59,7 @@ int test(char *URL)
int current = 0;
int i;
- for(i=0; i < NUM_HANDLES; i++)
+ for(i = 0; i < NUM_HANDLES; i++)
curl[i] = NULL;
start_test_timing();
@@ -67,7 +67,7 @@ int test(char *URL)
global_init(CURL_GLOBAL_ALL);
/* get NUM_HANDLES easy handles */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
easy_init(curl[i]);
/* specify target */
easy_setopt(curl[i], CURLOPT_URL, URL);
@@ -145,7 +145,7 @@ test_cleanup:
/* test 526 and 528 */
/* proper cleanup sequence - type PB */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
curl_multi_remove_handle(m, curl[i]);
curl_easy_cleanup(curl[i]);
}
@@ -162,7 +162,7 @@ test_cleanup:
will be leaked, let's use undocumented cleanup sequence - type UB */
if(res)
- for(i=0; i < NUM_HANDLES; i++)
+ for(i = 0; i < NUM_HANDLES; i++)
curl_easy_cleanup(curl[i]);
curl_multi_cleanup(m);
@@ -173,7 +173,7 @@ test_cleanup:
/* test 532 */
/* undocumented cleanup sequence - type UB */
- for(i=0; i < NUM_HANDLES; i++)
+ for(i = 0; i < NUM_HANDLES; i++)
curl_easy_cleanup(curl[i]);
curl_multi_cleanup(m);
curl_global_cleanup();
diff --git a/tests/libtest/lib530.c b/tests/libtest/lib530.c
index 82bfab36c..e7726fbc3 100644
--- a/tests/libtest/lib530.c
+++ b/tests/libtest/lib530.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -39,7 +39,7 @@ int test(char *URL)
char target_url[256];
int handles_added = 0;
- for(i=0; i < NUM_HANDLES; i++)
+ for(i = 0; i < NUM_HANDLES; i++)
curl[i] = NULL;
start_test_timing();
@@ -49,7 +49,7 @@ int test(char *URL)
multi_init(m);
/* get NUM_HANDLES easy handles */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
/* get an easy handle */
easy_init(curl[i]);
/* specify target */
@@ -110,7 +110,7 @@ test_cleanup:
/* proper cleanup sequence - type PB */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
curl_multi_remove_handle(m, curl[i]);
curl_easy_cleanup(curl[i]);
}
diff --git a/tests/libtest/lib533.c b/tests/libtest/lib533.c
index 706b269fe..ceb71bf7b 100644
--- a/tests/libtest/lib533.c
+++ b/tests/libtest/lib533.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2011, 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -37,7 +37,7 @@ int test(char *URL)
CURL *curl = NULL;
int running;
CURLM *m = NULL;
- int current=0;
+ int current = 0;
start_test_timing();
diff --git a/tests/libtest/lib540.c b/tests/libtest/lib540.c
index ac862092f..61f635f69 100644
--- a/tests/libtest/lib540.c
+++ b/tests/libtest/lib540.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -165,7 +165,7 @@ static int loop(int num, CURLM *cm, const char *url, const char *userpwd,
curl_easy_strerror(msg->data.result));
curl_multi_remove_handle(cm, e);
curl_easy_cleanup(e);
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
if(eh[i] == e) {
eh[i] = NULL;
break;
@@ -192,7 +192,7 @@ int test(char *URL)
int res = 0;
int i;
- for(i=0; i < NUM_HANDLES; i++)
+ for(i = 0; i < NUM_HANDLES; i++)
eh[i] = NULL;
start_test_timing();
@@ -234,7 +234,7 @@ test_cleanup:
/* proper cleanup sequence - type PB */
- for(i=0; i < NUM_HANDLES; i++) {
+ for(i = 0; i < NUM_HANDLES; i++) {
curl_multi_remove_handle(cm, eh[i]);
curl_easy_cleanup(eh[i]);
}
diff --git a/tests/libtest/lib544.c b/tests/libtest/lib544.c
index 28eacdaf6..1f832d2a6 100644
--- a/tests/libtest/lib544.c
+++ b/tests/libtest/lib544.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -40,7 +40,7 @@ static char teststring[] =
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib547.c b/tests/libtest/lib547.c
index ce967c085..3db4890de 100644
--- a/tests/libtest/lib547.c
+++ b/tests/libtest/lib547.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -82,7 +82,7 @@ int test(char *URL)
CURLcode res;
CURL *curl;
#ifndef LIB548
- int counter=0;
+ int counter = 0;
#endif
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
diff --git a/tests/libtest/lib552.c b/tests/libtest/lib552.c
index 9cae45993..e42ba34f9 100644
--- a/tests/libtest/lib552.c
+++ b/tests/libtest/lib552.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -40,7 +40,7 @@ void dump(const char *text,
size_t i;
size_t c;
- unsigned int width=0x10;
+ unsigned int width = 0x10;
if(nohex)
/* without the hex output, we can fit more on screen */
@@ -48,7 +48,7 @@ void dump(const char *text,
fprintf(stream, "%s, %d bytes (0x%x)\n", text, (int)size, (int)size);
- for(i=0; i<size; i+= width) {
+ for(i = 0; i<size; i+= width) {
fprintf(stream, "%04x: ", (int)i);
@@ -63,14 +63,14 @@ void dump(const char *text,
for(c = 0; (c < width) && (i+c < size); c++) {
/* check for 0D0A; if found, skip past and start a new line of output */
- if(nohex && (i+c+1 < size) && ptr[i+c]==0x0D && ptr[i+c+1]==0x0A) {
+ if(nohex && (i+c+1 < size) && ptr[i+c] == 0x0D && ptr[i+c+1] == 0x0A) {
i+=(c+2-width);
break;
}
fprintf(stream, "%c",
- (ptr[i+c]>=0x20) && (ptr[i+c]<0x80)?ptr[i+c]:'.');
+ (ptr[i+c] >= 0x20) && (ptr[i+c]<0x80)?ptr[i+c]:'.');
/* check again for 0D0A, to avoid an extra \n if it's at width */
- if(nohex && (i+c+2 < size) && ptr[i+c+1]==0x0D && ptr[i+c+2]==0x0A) {
+ if(nohex && (i+c+2 < size) && ptr[i+c+1] == 0x0D && ptr[i+c+2] == 0x0A) {
i+=(c+3-width);
break;
}
@@ -182,7 +182,7 @@ int test(char *URL)
test_setopt(curl, CURLOPT_VERBOSE, 1L);
/* setup repeated data string */
- for(i=0; i < sizeof(databuf); ++i)
+ for(i = 0; i < sizeof(databuf); ++i)
databuf[i] = fill[i % sizeof fill];
/* Post */
diff --git a/tests/libtest/lib553.c b/tests/libtest/lib553.c
index 288f4c1d1..c06561e1d 100644
--- a/tests/libtest/lib553.c
+++ b/tests/libtest/lib553.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -32,7 +32,7 @@
static size_t myreadfunc(void *ptr, size_t size, size_t nmemb, void *stream)
{
- static size_t total=POSTLEN;
+ static size_t total = POSTLEN;
static char buf[1024];
(void)stream;
@@ -60,7 +60,7 @@ int test(char *URL)
CURL *curl;
CURLcode res = CURLE_FAILED_INIT;
int i;
- struct curl_slist *headerlist=NULL, *hl;
+ struct curl_slist *headerlist = NULL, *hl;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
@@ -77,7 +77,7 @@ int test(char *URL)
for(i = 0; i < NUM_HEADERS; i++) {
int len = snprintf(buf, sizeof(buf), "Header%d: ", i);
memset(&buf[len], 'A', SIZE_HEADERS);
- buf[len + SIZE_HEADERS]=0; /* zero terminate */
+ buf[len + SIZE_HEADERS] = 0; /* zero terminate */
hl = curl_slist_append(headerlist, buf);
if(!hl)
goto test_cleanup;
diff --git a/tests/libtest/lib554.c b/tests/libtest/lib554.c
index 083746243..936d0a10a 100644
--- a/tests/libtest/lib554.c
+++ b/tests/libtest/lib554.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -67,11 +67,11 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
static int once(char *URL, bool oldstyle)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
CURLFORMcode formrc;
- struct curl_httppost *formpost=NULL;
- struct curl_httppost *lastptr=NULL;
+ struct curl_httppost *formpost = NULL;
+ struct curl_httppost *lastptr = NULL;
struct WriteThis pooh;
struct WriteThis pooh2;
diff --git a/tests/libtest/lib555.c b/tests/libtest/lib555.c
index 8156a95e7..464f6e0b0 100644
--- a/tests/libtest/lib555.c
+++ b/tests/libtest/lib555.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -77,9 +77,9 @@ int test(char *URL)
{
int res = 0;
CURL *curl = NULL;
- int counter=0;
+ int counter = 0;
CURLM *m = NULL;
- int running=1;
+ int running = 1;
start_test_timing();
diff --git a/tests/libtest/lib557.c b/tests/libtest/lib557.c
index c718be4ee..df63d9c6b 100644
--- a/tests/libtest/lib557.c
+++ b/tests/libtest/lib557.c
@@ -129,7 +129,7 @@ static int test_unsigned_short_formatting(void)
#if (SIZEOF_SHORT == 1)
- i=1; us_test[i].num = 0xFFU; us_test[i].expected = "256";
+ i = 1; us_test[i].num = 0xFFU; us_test[i].expected = "256";
i++; us_test[i].num = 0xF0U; us_test[i].expected = "240";
i++; us_test[i].num = 0x0FU; us_test[i].expected = "15";
@@ -146,7 +146,7 @@ static int test_unsigned_short_formatting(void)
#elif (SIZEOF_SHORT == 2)
- i=1; us_test[i].num = 0xFFFFU; us_test[i].expected = "65535";
+ i = 1; us_test[i].num = 0xFFFFU; us_test[i].expected = "65535";
i++; us_test[i].num = 0xFF00U; us_test[i].expected = "65280";
i++; us_test[i].num = 0x00FFU; us_test[i].expected = "255";
@@ -167,7 +167,7 @@ static int test_unsigned_short_formatting(void)
#elif (SIZEOF_SHORT == 4)
- i=1; us_test[i].num = 0xFFFFFFFFU; us_test[i].expected = "4294967295";
+ i = 1; us_test[i].num = 0xFFFFFFFFU; us_test[i].expected = "4294967295";
i++; us_test[i].num = 0xFFFF0000U; us_test[i].expected = "4294901760";
i++; us_test[i].num = 0x0000FFFFU; us_test[i].expected = "65535";
@@ -201,9 +201,9 @@ static int test_unsigned_short_formatting(void)
#endif
- for(i=1; i<=num_ushort_tests; i++) {
+ for(i = 1; i <= num_ushort_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
us_test[i].result[j] = 'X';
us_test[i].result[BUFSZ-1] = '\0';
@@ -236,7 +236,7 @@ static int test_signed_short_formatting(void)
#if (SIZEOF_SHORT == 1)
- i=1; ss_test[i].num = 0x7F; ss_test[i].expected = "127";
+ i = 1; ss_test[i].num = 0x7F; ss_test[i].expected = "127";
i++; ss_test[i].num = 0x70; ss_test[i].expected = "112";
i++; ss_test[i].num = 0x07; ss_test[i].expected = "7";
@@ -261,7 +261,7 @@ static int test_signed_short_formatting(void)
#elif (SIZEOF_SHORT == 2)
- i=1; ss_test[i].num = 0x7FFF; ss_test[i].expected = "32767";
+ i = 1; ss_test[i].num = 0x7FFF; ss_test[i].expected = "32767";
i++; ss_test[i].num = 0x7FFE; ss_test[i].expected = "32766";
i++; ss_test[i].num = 0x7FFD; ss_test[i].expected = "32765";
i++; ss_test[i].num = 0x7F00; ss_test[i].expected = "32512";
@@ -304,7 +304,7 @@ static int test_signed_short_formatting(void)
#elif (SIZEOF_SHORT == 4)
- i=1; ss_test[i].num = 0x7FFFFFFF; ss_test[i].expected = "2147483647";
+ i = 1; ss_test[i].num = 0x7FFFFFFF; ss_test[i].expected = "2147483647";
i++; ss_test[i].num = 0x7FFFFFFE; ss_test[i].expected = "2147483646";
i++; ss_test[i].num = 0x7FFFFFFD; ss_test[i].expected = "2147483645";
i++; ss_test[i].num = 0x7FFF0000; ss_test[i].expected = "2147418112";
@@ -371,9 +371,9 @@ static int test_signed_short_formatting(void)
#endif
- for(i=1; i<=num_sshort_tests; i++) {
+ for(i = 1; i <= num_sshort_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
ss_test[i].result[j] = 'X';
ss_test[i].result[BUFSZ-1] = '\0';
@@ -406,7 +406,7 @@ static int test_unsigned_int_formatting(void)
#if (SIZEOF_INT == 2)
- i=1; ui_test[i].num = 0xFFFFU; ui_test[i].expected = "65535";
+ i = 1; ui_test[i].num = 0xFFFFU; ui_test[i].expected = "65535";
i++; ui_test[i].num = 0xFF00U; ui_test[i].expected = "65280";
i++; ui_test[i].num = 0x00FFU; ui_test[i].expected = "255";
@@ -427,7 +427,7 @@ static int test_unsigned_int_formatting(void)
#elif (SIZEOF_INT == 4)
- i=1; ui_test[i].num = 0xFFFFFFFFU; ui_test[i].expected = "4294967295";
+ i = 1; ui_test[i].num = 0xFFFFFFFFU; ui_test[i].expected = "4294967295";
i++; ui_test[i].num = 0xFFFF0000U; ui_test[i].expected = "4294901760";
i++; ui_test[i].num = 0x0000FFFFU; ui_test[i].expected = "65535";
@@ -462,7 +462,7 @@ static int test_unsigned_int_formatting(void)
#elif (SIZEOF_INT == 8)
/* !checksrc! disable LONGLINE all */
- i=1; ui_test[i].num = 0xFFFFFFFFFFFFFFFFU; ui_test[i].expected = "18446744073709551615";
+ i = 1; ui_test[i].num = 0xFFFFFFFFFFFFFFFFU; ui_test[i].expected = "18446744073709551615";
i++; ui_test[i].num = 0xFFFFFFFF00000000U; ui_test[i].expected = "18446744069414584320";
i++; ui_test[i].num = 0x00000000FFFFFFFFU; ui_test[i].expected = "4294967295";
@@ -521,9 +521,9 @@ static int test_unsigned_int_formatting(void)
#endif
- for(i=1; i<=num_uint_tests; i++) {
+ for(i = 1; i <= num_uint_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
ui_test[i].result[j] = 'X';
ui_test[i].result[BUFSZ-1] = '\0';
@@ -556,7 +556,7 @@ static int test_signed_int_formatting(void)
#if (SIZEOF_INT == 2)
- i=1; si_test[i].num = 0x7FFF; si_test[i].expected = "32767";
+ i = 1; si_test[i].num = 0x7FFF; si_test[i].expected = "32767";
i++; si_test[i].num = 0x7FFE; si_test[i].expected = "32766";
i++; si_test[i].num = 0x7FFD; si_test[i].expected = "32765";
i++; si_test[i].num = 0x7F00; si_test[i].expected = "32512";
@@ -599,7 +599,7 @@ static int test_signed_int_formatting(void)
#elif (SIZEOF_INT == 4)
- i=1; si_test[i].num = 0x7FFFFFFF; si_test[i].expected = "2147483647";
+ i = 1; si_test[i].num = 0x7FFFFFFF; si_test[i].expected = "2147483647";
i++; si_test[i].num = 0x7FFFFFFE; si_test[i].expected = "2147483646";
i++; si_test[i].num = 0x7FFFFFFD; si_test[i].expected = "2147483645";
i++; si_test[i].num = 0x7FFF0000; si_test[i].expected = "2147418112";
@@ -666,7 +666,7 @@ static int test_signed_int_formatting(void)
#elif (SIZEOF_INT == 8)
- i=1; si_test[i].num = 0x7FFFFFFFFFFFFFFF; si_test[i].expected = "9223372036854775807";
+ i = 1; si_test[i].num = 0x7FFFFFFFFFFFFFFF; si_test[i].expected = "9223372036854775807";
i++; si_test[i].num = 0x7FFFFFFFFFFFFFFE; si_test[i].expected = "9223372036854775806";
i++; si_test[i].num = 0x7FFFFFFFFFFFFFFD; si_test[i].expected = "9223372036854775805";
i++; si_test[i].num = 0x7FFFFFFF00000000; si_test[i].expected = "9223372032559808512";
@@ -749,9 +749,9 @@ static int test_signed_int_formatting(void)
#endif
- for(i=1; i<=num_sint_tests; i++) {
+ for(i = 1; i <= num_sint_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
si_test[i].result[j] = 'X';
si_test[i].result[BUFSZ-1] = '\0';
@@ -784,7 +784,7 @@ static int test_unsigned_long_formatting(void)
#if (SIZEOF_LONG == 2)
- i=1; ul_test[i].num = 0xFFFFUL; ul_test[i].expected = "65535";
+ i = 1; ul_test[i].num = 0xFFFFUL; ul_test[i].expected = "65535";
i++; ul_test[i].num = 0xFF00UL; ul_test[i].expected = "65280";
i++; ul_test[i].num = 0x00FFUL; ul_test[i].expected = "255";
@@ -805,7 +805,7 @@ static int test_unsigned_long_formatting(void)
#elif (SIZEOF_LONG == 4)
- i=1; ul_test[i].num = 0xFFFFFFFFUL; ul_test[i].expected = "4294967295";
+ i = 1; ul_test[i].num = 0xFFFFFFFFUL; ul_test[i].expected = "4294967295";
i++; ul_test[i].num = 0xFFFF0000UL; ul_test[i].expected = "4294901760";
i++; ul_test[i].num = 0x0000FFFFUL; ul_test[i].expected = "65535";
@@ -839,7 +839,7 @@ static int test_unsigned_long_formatting(void)
#elif (SIZEOF_LONG == 8)
- i=1; ul_test[i].num = 0xFFFFFFFFFFFFFFFFUL; ul_test[i].expected = "18446744073709551615";
+ i = 1; ul_test[i].num = 0xFFFFFFFFFFFFFFFFUL; ul_test[i].expected = "18446744073709551615";
i++; ul_test[i].num = 0xFFFFFFFF00000000UL; ul_test[i].expected = "18446744069414584320";
i++; ul_test[i].num = 0x00000000FFFFFFFFUL; ul_test[i].expected = "4294967295";
@@ -898,9 +898,9 @@ static int test_unsigned_long_formatting(void)
#endif
- for(i=1; i<=num_ulong_tests; i++) {
+ for(i = 1; i <= num_ulong_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
ul_test[i].result[j] = 'X';
ul_test[i].result[BUFSZ-1] = '\0';
@@ -933,7 +933,7 @@ static int test_signed_long_formatting(void)
#if (SIZEOF_LONG == 2)
- i=1; sl_test[i].num = 0x7FFFL; sl_test[i].expected = "32767";
+ i = 1; sl_test[i].num = 0x7FFFL; sl_test[i].expected = "32767";
i++; sl_test[i].num = 0x7FFEL; sl_test[i].expected = "32766";
i++; sl_test[i].num = 0x7FFDL; sl_test[i].expected = "32765";
i++; sl_test[i].num = 0x7F00L; sl_test[i].expected = "32512";
@@ -976,7 +976,7 @@ static int test_signed_long_formatting(void)
#elif (SIZEOF_LONG == 4)
- i=1; sl_test[i].num = 0x7FFFFFFFL; sl_test[i].expected = "2147483647";
+ i = 1; sl_test[i].num = 0x7FFFFFFFL; sl_test[i].expected = "2147483647";
i++; sl_test[i].num = 0x7FFFFFFEL; sl_test[i].expected = "2147483646";
i++; sl_test[i].num = 0x7FFFFFFDL; sl_test[i].expected = "2147483645";
i++; sl_test[i].num = 0x7FFF0000L; sl_test[i].expected = "2147418112";
@@ -1043,7 +1043,7 @@ static int test_signed_long_formatting(void)
#elif (SIZEOF_LONG == 8)
- i=1; sl_test[i].num = 0x7FFFFFFFFFFFFFFFL; sl_test[i].expected = "9223372036854775807";
+ i = 1; sl_test[i].num = 0x7FFFFFFFFFFFFFFFL; sl_test[i].expected = "9223372036854775807";
i++; sl_test[i].num = 0x7FFFFFFFFFFFFFFEL; sl_test[i].expected = "9223372036854775806";
i++; sl_test[i].num = 0x7FFFFFFFFFFFFFFDL; sl_test[i].expected = "9223372036854775805";
i++; sl_test[i].num = 0x7FFFFFFF00000000L; sl_test[i].expected = "9223372032559808512";
@@ -1126,9 +1126,9 @@ static int test_signed_long_formatting(void)
#endif
- for(i=1; i<=num_slong_tests; i++) {
+ for(i = 1; i <= num_slong_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
sl_test[i].result[j] = 'X';
sl_test[i].result[BUFSZ-1] = '\0';
@@ -1161,7 +1161,7 @@ static int test_curl_off_t_formatting(void)
#if (SIZEOF_CURL_OFF_T == 2)
- i=1; co_test[i].num = MPRNT_OFF_T_C(0x7FFF); co_test[i].expected = "32767";
+ i = 1; co_test[i].num = MPRNT_OFF_T_C(0x7FFF); co_test[i].expected = "32767";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFE); co_test[i].expected = "32766";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFD); co_test[i].expected = "32765";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7F00); co_test[i].expected = "32512";
@@ -1204,7 +1204,7 @@ static int test_curl_off_t_formatting(void)
#elif (SIZEOF_CURL_OFF_T == 4)
- i=1; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFF); co_test[i].expected = "2147483647";
+ i = 1; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFF); co_test[i].expected = "2147483647";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFE); co_test[i].expected = "2147483646";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFD); co_test[i].expected = "2147483645";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFF0000); co_test[i].expected = "2147418112";
@@ -1271,7 +1271,7 @@ static int test_curl_off_t_formatting(void)
#elif (SIZEOF_CURL_OFF_T == 8)
- i=1; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFFFFFFFFFF); co_test[i].expected = "9223372036854775807";
+ i = 1; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFFFFFFFFFF); co_test[i].expected = "9223372036854775807";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFFFFFFFFFE); co_test[i].expected = "9223372036854775806";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFFFFFFFFFD); co_test[i].expected = "9223372036854775805";
i++; co_test[i].num = MPRNT_OFF_T_C(0x7FFFFFFF00000000); co_test[i].expected = "9223372032559808512";
@@ -1354,9 +1354,9 @@ static int test_curl_off_t_formatting(void)
#endif
- for(i=1; i<=num_cofft_tests; i++) {
+ for(i = 1; i <= num_cofft_tests; i++) {
- for(j=0; j<BUFSZ; j++)
+ for(j = 0; j<BUFSZ; j++)
co_test[i].result[j] = 'X';
co_test[i].result[BUFSZ-1] = '\0';
diff --git a/tests/libtest/lib567.c b/tests/libtest/lib567.c
index f9f55e3c0..64fb29afb 100644
--- a/tests/libtest/lib567.c
+++ b/tests/libtest/lib567.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -30,7 +30,7 @@ int test(char *URL)
{
CURLcode res;
CURL *curl;
- struct curl_slist *custom_headers=NULL;
+ struct curl_slist *custom_headers = NULL;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib568.c b/tests/libtest/lib568.c
index 0cdef812b..3bb53f61e 100644
--- a/tests/libtest/lib568.c
+++ b/tests/libtest/lib568.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -47,8 +47,8 @@ int test(char *URL)
FILE *sdpf = NULL;
struct_stat file_info;
char *stream_uri = NULL;
- int request=1;
- struct curl_slist *custom_headers=NULL;
+ int request = 1;
+ struct curl_slist *custom_headers = NULL;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib569.c b/tests/libtest/lib569.c
index d7381d9a2..c18c882b9 100644
--- a/tests/libtest/lib569.c
+++ b/tests/libtest/lib569.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -37,7 +37,7 @@ int test(char *URL)
CURL *curl;
char *stream_uri = NULL;
char *rtsp_session_id;
- int request=1;
+ int request = 1;
int i;
FILE *idfile = NULL;
diff --git a/tests/libtest/lib570.c b/tests/libtest/lib570.c
index 9d9b5a134..1756a8615 100644
--- a/tests/libtest/lib570.c
+++ b/tests/libtest/lib570.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -32,7 +32,7 @@ int test(char *URL)
{
int res;
CURL *curl;
- int request=1;
+ int request = 1;
char *stream_uri = NULL;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
diff --git a/tests/libtest/lib571.c b/tests/libtest/lib571.c
index f19b643ff..21aa267b7 100644
--- a/tests/libtest/lib571.c
+++ b/tests/libtest/lib571.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -103,7 +103,7 @@ int test(char *URL)
int res;
CURL *curl;
char *stream_uri = NULL;
- int request=1;
+ int request = 1;
FILE *protofile = NULL;
protofile = fopen(libtest_arg2, "wb");
diff --git a/tests/libtest/lib572.c b/tests/libtest/lib572.c
index 47a9da535..a78c9358d 100644
--- a/tests/libtest/lib572.c
+++ b/tests/libtest/lib572.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -47,8 +47,8 @@ int test(char *URL)
FILE *paramsf = NULL;
struct_stat file_info;
char *stream_uri = NULL;
- int request=1;
- struct curl_slist *custom_headers=NULL;
+ int request = 1;
+ struct curl_slist *custom_headers = NULL;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib578.c b/tests/libtest/lib578.c
index 41b23db34..1b4ee526c 100644
--- a/tests/libtest/lib578.c
+++ b/tests/libtest/lib578.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -51,7 +51,7 @@ static int progress_callback(void *clientp, double dltotal, double dlnow,
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib579.c b/tests/libtest/lib579.c
index 61aa4f5df..cba4b1cb4 100644
--- a/tests/libtest/lib579.c
+++ b/tests/libtest/lib579.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -87,7 +87,7 @@ static size_t read_callback(void *ptr, size_t size, size_t nmemb, void *userp)
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
struct curl_slist *slist = NULL;
struct WriteThis pooh;
pooh.counter = 0;
diff --git a/tests/libtest/lib586.c b/tests/libtest/lib586.c
index 859ef3430..669f71c15 100644
--- a/tests/libtest/lib586.c
+++ b/tests/libtest/lib586.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -99,7 +99,7 @@ static void *fire(void *ptr)
CURLcode code;
struct Tdata *tdata = (struct Tdata*)ptr;
CURL *curl;
- int i=0;
+ int i = 0;
curl = curl_easy_init();
if(!curl) {
@@ -185,7 +185,7 @@ int test(char *URL)
res = 0;
/* start treads */
- for(i=1; i<=THREADS; i++) {
+ for(i = 1; i <= THREADS; i++) {
/* set thread data */
tdata.url = URL;
@@ -218,7 +218,7 @@ int test(char *URL)
/* try to free share, expect to fail because share is in use*/
printf("try SHARE_CLEANUP...\n");
scode = curl_share_cleanup(share);
- if(scode==CURLSHE_OK) {
+ if(scode == CURLSHE_OK) {
fprintf(stderr, "curl_share_cleanup succeed but error expected\n");
share = NULL;
}
@@ -235,7 +235,7 @@ test_cleanup:
/* free share */
printf("SHARE_CLEANUP\n");
scode = curl_share_cleanup(share);
- if(scode!=CURLSHE_OK)
+ if(scode != CURLSHE_OK)
fprintf(stderr, "curl_share_cleanup failed, code errno %d\n",
(int)scode);
diff --git a/tests/libtest/lib589.c b/tests/libtest/lib589.c
index 1e5ebb1e4..667459d0d 100644
--- a/tests/libtest/lib589.c
+++ b/tests/libtest/lib589.c
@@ -26,7 +26,7 @@
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
fprintf(stderr, "curl_global_init() failed\n");
diff --git a/tests/libtest/lib599.c b/tests/libtest/lib599.c
index 843fb2121..0e05977b5 100644
--- a/tests/libtest/lib599.c
+++ b/tests/libtest/lib599.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -42,7 +42,7 @@ static int progress_callback(void *clientp, double dltotal,
int test(char *URL)
{
CURL *curl;
- CURLcode res=CURLE_OK;
+ CURLcode res = CURLE_OK;
double content_length = 0.0;
if(curl_global_init(CURL_GLOBAL_ALL) != CURLE_OK) {
diff --git a/tests/libtest/mk-lib1521.pl b/tests/libtest/mk-lib1521.pl
index fe7e65d7a..6ded47220 100644
--- a/tests/libtest/mk-lib1521.pl
+++ b/tests/libtest/mk-lib1521.pl
@@ -143,9 +143,9 @@ int test(char *URL)
void *conv_to_network_cb = NULL;
void *conv_from_utf8_cb = NULL;
void *interleavecb = NULL;
- char *stringpointerextra=(char *)"moooo";
- struct curl_slist *slist=NULL;
- struct curl_httppost *httppost=NULL;
+ char *stringpointerextra = (char *)"moooo";
+ struct curl_slist *slist = NULL;
+ struct curl_httppost *httppost = NULL;
curl_mime *mimepost = NULL;
FILE *stream = stderr;
struct data object;