mirror of
https://github.com/transmission/transmission
synced 2024-12-22 07:42:37 +00:00
fix: don't process http announce error if already succeeded (#7086)
This commit is contained in:
parent
5260331732
commit
461e178c8f
1 changed files with 2 additions and 6 deletions
|
@ -154,16 +154,12 @@ void onAnnounceDone(tr_web::FetchResponse const& web_response)
|
||||||
}
|
}
|
||||||
else if (got_all_responses)
|
else if (got_all_responses)
|
||||||
{
|
{
|
||||||
auto const* response_used = &response;
|
|
||||||
|
|
||||||
// All requests have been answered, but none were successful.
|
// All requests have been answered, but none were successful.
|
||||||
// Choose the one that went further to report.
|
// Choose the one that went further to report.
|
||||||
if (data->previous_response && !response.did_connect && !response.did_timeout)
|
if (data->previous_response)
|
||||||
{
|
{
|
||||||
response_used = &*data->previous_response;
|
data->on_response(response.did_connect || response.did_timeout ? response : *data->previous_response);
|
||||||
}
|
}
|
||||||
|
|
||||||
data->on_response(*response_used);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue