commit 4720ace1a7d9b5cc83f9d3adceda12443d106c24 parent 33ee100c86cec635fce0d2d1eb438d9552ed5201 Author: Christian Grothoff <christian@grothoff.org> Date: Tue, 7 Jun 2022 17:29:24 +0200 -fix memory leaks in tests Diffstat:
| M | src/testcurl/test_long_header.c | | | 6 | ++++-- |
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/testcurl/test_long_header.c b/src/testcurl/test_long_header.c @@ -142,8 +142,9 @@ testLongUrlGet (size_t buff_size) } c = curl_easy_init (); url = malloc (VERY_LONG); - if (url == NULL) + if (NULL == url) { + curl_easy_cleanup (c); MHD_stop_daemon (d); return 1; } @@ -235,8 +236,9 @@ testLongHeaderGet (size_t buff_size) } c = curl_easy_init (); url = malloc (VERY_LONG); - if (url == NULL) + if (NULL == url) { + curl_easy_cleanup (c); MHD_stop_daemon (d); return 16; }