aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/data/test14046
-rw-r--r--tests/libtest/lib643.c16
2 files changed, 11 insertions, 11 deletions
diff --git a/tests/data/test1404 b/tests/data/test1404
index 60ed58a16..a3ec66ef7 100644
--- a/tests/data/test1404
+++ b/tests/data/test1404
@@ -123,8 +123,8 @@ int main(int argc, char *argv[])
curl_easy_setopt(hnd, CURLOPT_HEADER, 1L);
mime1 = curl_mime_init(hnd);
part1 = curl_mime_addpart(mime1);
- curl_mime_data(part1, "value", -1);
- curl_mime_name(part1, "name", -1);
+ curl_mime_data(part1, "value", CURL_ZERO_TERMINATED);
+ curl_mime_name(part1, "name", CURL_ZERO_TERMINATED);
part1 = curl_mime_addpart(mime1);
mime2 = curl_mime_init(hnd);
part2 = curl_mime_addpart(mime2);
@@ -138,7 +138,7 @@ int main(int argc, char *argv[])
slist1 = NULL;
curl_mime_subparts(part1, mime2);
mime2 = NULL;
- curl_mime_name(part1, "file", -1);
+ curl_mime_name(part1, "file", CURL_ZERO_TERMINATED);
curl_easy_setopt(hnd, CURLOPT_MIMEPOST, mime1);
curl_easy_setopt(hnd, CURLOPT_USERAGENT, "stripped");
curl_easy_setopt(hnd, CURLOPT_MAXREDIRS, 50L);
diff --git a/tests/libtest/lib643.c b/tests/libtest/lib643.c
index ea5a96740..b2698f076 100644
--- a/tests/libtest/lib643.c
+++ b/tests/libtest/lib643.c
@@ -113,7 +113,7 @@ static int once(char *URL, bool oldstyle)
/* Fill in the file upload part */
if(oldstyle) {
- res = curl_mime_name(part, "sendfile", -1);
+ res = curl_mime_name(part, "sendfile", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_data_cb(part, datasize, read_callback,
NULL, NULL, &pooh);
@@ -122,7 +122,7 @@ static int once(char *URL, bool oldstyle)
}
else {
/* new style */
- res = curl_mime_name(part, "sendfile alternative", -1);
+ res = curl_mime_name(part, "sendfile alternative", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_data_cb(part, datasize, read_callback,
NULL, NULL, &pooh);
@@ -151,7 +151,7 @@ static int once(char *URL, bool oldstyle)
return TEST_ERR_MAJOR_BAD;
}
/* Fill in the file upload part */
- res = curl_mime_name(part, "callbackdata", -1);
+ res = curl_mime_name(part, "callbackdata", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_data_cb(part, datasize, read_callback,
NULL, NULL, &pooh2);
@@ -169,7 +169,7 @@ static int once(char *URL, bool oldstyle)
}
/* Fill in the filename field */
- res = curl_mime_name(part, "filename", -1);
+ res = curl_mime_name(part, "filename", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_data(part,
#ifdef CURL_DOES_CONVERSIONS
@@ -179,7 +179,7 @@ static int once(char *URL, bool oldstyle)
#else
"postit2.c",
#endif
- -1);
+ CURL_ZERO_TERMINATED);
if(res)
printf("curl_mime_xxx(3) = %s\n", curl_easy_strerror(res));
@@ -193,7 +193,7 @@ static int once(char *URL, bool oldstyle)
curl_global_cleanup();
return TEST_ERR_MAJOR_BAD;
}
- res = curl_mime_name(part, "submit", -1);
+ res = curl_mime_name(part, "submit", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_data(part,
#ifdef CURL_DOES_CONVERSIONS
@@ -203,7 +203,7 @@ static int once(char *URL, bool oldstyle)
#else
"send",
#endif
- -1);
+ CURL_ZERO_TERMINATED);
if(res)
printf("curl_mime_xxx(4) = %s\n", curl_easy_strerror(res));
@@ -216,7 +216,7 @@ static int once(char *URL, bool oldstyle)
curl_global_cleanup();
return TEST_ERR_MAJOR_BAD;
}
- res = curl_mime_name(part, "somename", -1);
+ res = curl_mime_name(part, "somename", CURL_ZERO_TERMINATED);
if(!res)
res = curl_mime_filename(part, "somefile.txt");
if(!res)