1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2026-01-07 02:53:58 +00:00

1. Updated so if Server Address cannot be resolved, it will not say "connecting"

2. Updated, so resolve failure + cache miss, will not prevent retry.
This commit is contained in:
Bryan Roe
2019-06-21 14:42:09 -07:00
parent c9ed96f5a0
commit bf173d408c

View File

@@ -3285,9 +3285,6 @@ void MeshServer_ConnectEx(MeshAgentHostContainer *agent)
}
}
printf("Connecting to: %s\n", serverUrl);
if (agent->logUpdate != 0 || agent->controlChannelDebug != 0) { ILIBLOGMESSAGEX("Connecting to: %s\n", serverUrl); }
ILibRemoteLogging_printf(ILibChainGetLogger(agent->chain), ILibRemoteLogging_Modules_Agent_GuardPost, ILibRemoteLogging_Flags_VerbosityLevel_1, "AgentCore: Attempting connection to: %s", serverUrl);
ILibDestructParserResults(rs);
@@ -3335,6 +3332,9 @@ void MeshServer_ConnectEx(MeshAgentHostContainer *agent)
if (meshServer.sin6_family != AF_UNSPEC)
{
printf("Connecting to: %s\n", serverUrl);
if (agent->logUpdate != 0 || agent->controlChannelDebug != 0) { ILIBLOGMESSAGEX("Connecting to: %s\n", serverUrl); }
ILibWebClient_AddWebSocketRequestHeaders(req, 65535, MeshServer_OnSendOK);
if (agent->webSocketMaskOverride != 0) { ILibHTTPPacket_Stash_Put(req, "_WebSocketMaskOverride", 22, (void*)(uintptr_t)0x01); }
@@ -3393,6 +3393,7 @@ void MeshServer_ConnectEx(MeshAgentHostContainer *agent)
else
{
ILibDestructPacket(req);
MeshServer_Connect(agent);
}
free(host);
}