From: Daniel Stenberg Date: Thu, 12 Dec 2019 14:08:19 +0000 (+0100) Subject: lib1557: fix mem-leak in OOM X-Git-Tag: curl-7_68_0~73 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6a15d1d4e574e7c41c67aa752c27ba0a3db21610;p=thirdparty%2Fcurl.git lib1557: fix mem-leak in OOM Closes #4709 --- diff --git a/tests/libtest/lib1557.c b/tests/libtest/lib1557.c index bd0f20a85d..d7132ad04d 100644 --- a/tests/libtest/lib1557.c +++ b/tests/libtest/lib1557.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2018, Daniel Stenberg, , et al. + * Copyright (C) 1998 - 2019, Daniel Stenberg, , et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -49,13 +49,13 @@ int test(char *URL) multi_perform(curlm, &running_handles); multi_remove_handle(curlm, curl2); - curl_easy_cleanup(curl2); /* If curl2 is still in the connect-pending list, this will crash */ multi_remove_handle(curlm, curl1); - curl_easy_cleanup(curl1); test_cleanup: + curl_easy_cleanup(curl1); + curl_easy_cleanup(curl2); curl_multi_cleanup(curlm); curl_global_cleanup(); return res;