1
0
Fork 0

Do not retry connect on canceled connections (#6559)

This commit is contained in:
Simon 2018-09-20 17:13:38 +02:00 committed by Jan
parent a93db9a6b9
commit 6db05b8b12
2 changed files with 2 additions and 2 deletions

View File

@ -213,7 +213,7 @@ void HttpConnection<ST>::tryConnect(unsigned retries) {
return;
}
FUERTE_LOG_DEBUG << "connecting failed: " << ec.message() << "\n";
if (retries > 0) {
if (retries > 0 && ec != asio_ns::error::operation_aborted) {
tryConnect(retries - 1);
} else {
shutdownConnection(ErrorCondition::CouldNotConnect);

View File

@ -134,7 +134,7 @@ void VstConnection<ST>::tryConnect(unsigned retries) {
return;
}
FUERTE_LOG_DEBUG << "connecting failed: " << ec.message() << "\n";
if (retries > 0) {
if (retries > 0 && ec != asio_ns::error::operation_aborted) {
tryConnect(retries - 1);
} else {
shutdownConnection(ErrorCondition::CouldNotConnect);