summaryrefslogtreecommitdiff
path: root/src/tool_main.c
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2014-02-23 15:10:18 +0000
committerSteve Holme <steve_holme@hotmail.com>2014-02-24 20:35:48 +0000
commitc27cc68815acd315c663e08ee9e3450b153f095f (patch)
tree3c8ee28c2347d069857b16259701ef911e8c2bb0 /src/tool_main.c
parent0af2322bc6dec10612d33de4b100d5dbc7be739f (diff)
downloadcurl-c27cc68815acd315c663e08ee9e3450b153f095f.tar.gz
tool_operate: Moved easy handle cleanup into tool_main
Diffstat (limited to 'src/tool_main.c')
-rw-r--r--src/tool_main.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/tool_main.c b/src/tool_main.c
index 009790493..7bdd253aa 100644
--- a/src/tool_main.c
+++ b/src/tool_main.c
@@ -172,13 +172,17 @@ static CURLcode main_init(struct GlobalConfig *config)
*/
static void main_free(struct GlobalConfig *config)
{
+ /* Cleanup the easy handle */
+ curl_easy_cleanup(config->easy);
+ config->easy = NULL;
+
/* Main cleanup */
curl_global_cleanup();
convert_cleanup();
metalink_cleanup();
/* Free the config structures */
- config_free(config->first);
+ config_free(config->last);
config->first = NULL;
config->last = NULL;
}