mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
BI-154 Fix isLocal detection
This commit is contained in:
parent
65b2812343
commit
ddf231e57f
@ -301,7 +301,11 @@ bool DDLWorker::initAndCheckTask(const String & entry_name, String & out_reason)
|
||||
for (const HostID & host : task->entry.hosts)
|
||||
{
|
||||
auto maybe_secure_port = context.getTCPPortSecure();
|
||||
bool is_local_port = maybe_secure_port ? host.isLocalAddress(*maybe_secure_port) : host.isLocalAddress(context.getTCPPort());
|
||||
bool is_local_port = false;
|
||||
if (maybe_secure_port)
|
||||
is_local_port = host.isLocalAddress(*maybe_secure_port);
|
||||
if (!is_local_port)
|
||||
is_local_port = host.isLocalAddress(context.getTCPPort());
|
||||
if (!is_local_port)
|
||||
continue;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user