From 4019ad5bb79261414a21de99577d64a92d885e4a Mon Sep 17 00:00:00 2001 From: "Alexander A. Klimov" Date: Fri, 24 Mar 2023 15:38:50 +0100 Subject: [PATCH] Fix compiler warnings by replacing x&&y||z with (x&&y)||z --- lib/base/tcpsocket.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/base/tcpsocket.hpp b/lib/base/tcpsocket.hpp index 7e64d57a5..9fc57d28e 100644 --- a/lib/base/tcpsocket.hpp +++ b/lib/base/tcpsocket.hpp @@ -54,7 +54,7 @@ void Connect(Socket& socket, const String& node, const String& service) } catch (const std::exception& ex) { auto se (dynamic_cast(&ex)); - if (se && se->code() == boost::asio::error::operation_aborted || ++current == result.end()) { + if ((se && se->code() == boost::asio::error::operation_aborted) || ++current == result.end()) { throw; } @@ -84,7 +84,7 @@ void Connect(Socket& socket, const String& node, const String& service, boost::a } catch (const std::exception& ex) { auto se (dynamic_cast(&ex)); - if (se && se->code() == boost::asio::error::operation_aborted || ++current == result.end()) { + if ((se && se->code() == boost::asio::error::operation_aborted) || ++current == result.end()) { throw; }