[mod_http_cache] Fix leaking curl handle in http_get()
This commit is contained in:
parent
92caab3647
commit
2ab600c71a
|
@ -1167,6 +1167,7 @@ static switch_status_t http_get(url_cache_t *cache, http_profile_t *profile, cac
|
||||||
switch_curl_easy_cleanup(curl_handle);
|
switch_curl_easy_cleanup(curl_handle);
|
||||||
close(get_data.fd);
|
close(get_data.fd);
|
||||||
} else {
|
} else {
|
||||||
|
switch_curl_easy_cleanup(curl_handle);
|
||||||
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "open() error: %s\n", strerror(errno));
|
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "open() error: %s\n", strerror(errno));
|
||||||
status = SWITCH_STATUS_GENERR;
|
status = SWITCH_STATUS_GENERR;
|
||||||
goto done;
|
goto done;
|
||||||
|
|
Loading…
Reference in New Issue