lib/curl/Request: merge two "try" blocks
This commit is contained in:
parent
19af364400
commit
b6013a92e0
|
@ -171,13 +171,7 @@ CurlRequest::Done(CURLcode result) noexcept
|
||||||
msg = curl_easy_strerror(result);
|
msg = curl_easy_strerror(result);
|
||||||
throw FormatRuntimeError("CURL failed: %s", msg);
|
throw FormatRuntimeError("CURL failed: %s", msg);
|
||||||
}
|
}
|
||||||
} catch (...) {
|
|
||||||
state = State::CLOSED;
|
|
||||||
handler.OnError(std::current_exception());
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
|
||||||
FinishBody();
|
FinishBody();
|
||||||
} catch (...) {
|
} catch (...) {
|
||||||
state = State::CLOSED;
|
state = State::CLOSED;
|
||||||
|
|
Loading…
Reference in New Issue