diff --git a/src/main.c b/src/main.c index 0c1c0a9..c25cc64 100644 --- a/src/main.c +++ b/src/main.c @@ -89,6 +89,9 @@ void call_proxy(struct curl_result* result, char* key){ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, curl_write); curl_easy_setopt(curl, CURLOPT_WRITEDATA, result); res = curl_easy_perform(curl); + if(res){ + curl_easy_cleanup(curl); + } } uv_buf_t handle_version(){