aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/messagebus/session.cpp
diff options
context:
space:
mode:
authorcepera <cepera@yandex-team.ru>2022-02-10 16:49:45 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:45 +0300
commit99e67b1db27953625d41d1f3eb45ff2517b4d697 (patch)
treee54d1799e55c6a3c58feb227f2a1f22aa07912c0 /library/cpp/messagebus/session.cpp
parent28045de07753ee182fc8e5ca778469d7a7c5bb20 (diff)
downloadydb-99e67b1db27953625d41d1f3eb45ff2517b4d697.tar.gz
Restoring authorship annotation for <cepera@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/messagebus/session.cpp')
-rw-r--r--library/cpp/messagebus/session.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/library/cpp/messagebus/session.cpp b/library/cpp/messagebus/session.cpp
index 46a7ece6a8..323c72bbb1 100644
--- a/library/cpp/messagebus/session.cpp
+++ b/library/cpp/messagebus/session.cpp
@@ -61,16 +61,16 @@ namespace NBus {
}
*hostName = host.substr(1, pos - 1);
-
+
pos++;
if (pos != host.length()) {
if (host[pos] != ':') {
// Do not allow '[...]a' but '[...]:' is ok (as for ipv4 before
return false;
}
-
+
*portNum = host.substr(pos + 1);
- }
+ }
} else {
size_t pos = host.find(':');
if (pos != TString::npos) {
@@ -78,22 +78,22 @@ namespace NBus {
// Treat ':<port>' as errors but allow or '<host>:' for compatibility.
return false;
}
-
+
*portNum = host.substr(pos + 1);
- }
-
+ }
+
*hostName = host.substr(0, pos);
- }
-
+ }
+
return true;
- }
-
+ }
+
/// registers external session on host:port with locator service
int TBusSession::RegisterService(const char* host, TBusKey start /*= YBUS_KEYMIN*/, TBusKey end /*= YBUS_KEYMAX*/, EIpVersion ipVersion) {
TString hostName;
TString port;
int portNum;
-
+
if (!SplitHost(host, &hostName, &port)) {
hostName = host;
}
@@ -113,8 +113,8 @@ namespace NBus {
}
TBusSession::~TBusSession() {
- }
-
+ }
+
}
TBusClientSessionPtr TBusClientSession::Create(TBusProtocol* proto, IBusClientHandler* handler, const TBusClientSessionConfig& config, TBusMessageQueuePtr queue) {