aboutsummaryrefslogtreecommitdiff
path: root/tests/libtest
diff options
context:
space:
mode:
Diffstat (limited to 'tests/libtest')
-rw-r--r--tests/libtest/lib539.c3
-rw-r--r--tests/libtest/lib568.c3
-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.c3
-rw-r--r--tests/libtest/lib582.c6
7 files changed, 8 insertions, 19 deletions
diff --git a/tests/libtest/lib539.c b/tests/libtest/lib539.c
index 923893fb2..053d29806 100644
--- a/tests/libtest/lib539.c
+++ b/tests/libtest/lib539.c
@@ -83,8 +83,7 @@ int test(char *URL)
test_cleanup:
curl_slist_free_all(slist);
- if(newURL)
- free(newURL);
+ free(newURL);
curl_easy_cleanup(curl);
curl_global_cleanup();
diff --git a/tests/libtest/lib568.c b/tests/libtest/lib568.c
index 12fc5e5d9..b6f5ab7ca 100644
--- a/tests/libtest/lib568.c
+++ b/tests/libtest/lib568.c
@@ -159,8 +159,7 @@ test_cleanup:
if(sdpf)
fclose(sdpf);
- if(stream_uri)
- free(stream_uri);
+ free(stream_uri);
if(custom_headers)
curl_slist_free_all(custom_headers);
diff --git a/tests/libtest/lib569.c b/tests/libtest/lib569.c
index 222f1e024..bc4887276 100644
--- a/tests/libtest/lib569.c
+++ b/tests/libtest/lib569.c
@@ -115,9 +115,7 @@ test_cleanup:
if(idfile)
fclose(idfile);
- if(stream_uri)
- free(stream_uri);
-
+ free(stream_uri);
curl_easy_cleanup(curl);
curl_global_cleanup();
diff --git a/tests/libtest/lib570.c b/tests/libtest/lib570.c
index 93ccab8ea..178f58f96 100644
--- a/tests/libtest/lib570.c
+++ b/tests/libtest/lib570.c
@@ -102,9 +102,7 @@ int test(char *URL)
}
test_cleanup:
-
- if(stream_uri)
- free(stream_uri);
+ free(stream_uri);
curl_easy_cleanup(curl);
curl_global_cleanup();
diff --git a/tests/libtest/lib571.c b/tests/libtest/lib571.c
index 3270300de..d8dad396b 100644
--- a/tests/libtest/lib571.c
+++ b/tests/libtest/lib571.c
@@ -195,9 +195,7 @@ int test(char *URL)
}
test_cleanup:
-
- if(stream_uri)
- free(stream_uri);
+ free(stream_uri);
if(protofile)
fclose(protofile);
diff --git a/tests/libtest/lib572.c b/tests/libtest/lib572.c
index 9b23c01a2..fd547b8b3 100644
--- a/tests/libtest/lib572.c
+++ b/tests/libtest/lib572.c
@@ -165,8 +165,7 @@ test_cleanup:
if(paramsf)
fclose(paramsf);
- if(stream_uri)
- free(stream_uri);
+ free(stream_uri);
if(custom_headers)
curl_slist_free_all(custom_headers);
diff --git a/tests/libtest/lib582.c b/tests/libtest/lib582.c
index 952efb4ed..4c3ea6f60 100644
--- a/tests/libtest/lib582.c
+++ b/tests/libtest/lib582.c
@@ -357,10 +357,8 @@ test_cleanup:
fclose(hd_src);
/* free local memory */
- if(sockets.read.sockets)
- free(sockets.read.sockets);
- if(sockets.write.sockets)
- free(sockets.write.sockets);
+ free(sockets.read.sockets);
+ free(sockets.write.sockets);
return res;
}