[core] Fix bugprone-exception-escape errors

As reported by clang-tidy-8.
This commit is contained in:
Thiago Marcos P. Santos
2020-03-27 18:30:35 +02:00
parent 0f235ac6d5
commit ea19e817c0
2 changed files with 10 additions and 2 deletions

View File

@@ -266,7 +266,10 @@ HTTPRequest::HTTPRequest(HTTPFileSource::Impl* context_, Resource resource_, Fil
}
HTTPRequest::~HTTPRequest() {
handleError(curl_multi_remove_handle(context->multi, handle));
if (curl_multi_remove_handle(context->multi, handle) != CURLM_OK) {
mbgl::Log::Error(mbgl::Event::HttpRequest, "Error removing curl multi handle");
}
context->returnHandle(handle);
handle = nullptr;