1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-11-26 11:29:53 +03:00

src/Mayaqua/Network.c: remove reccuring check

found by PVS analyzer

src/Mayaqua/Network.c	18715	err	V571 Recurring check. The 'if (u->GetNatTIpThread == NULL)' condition was already verified in line 18712.
This commit is contained in:
Ilya Shipitsin 2018-11-04 01:04:58 +05:00
parent dcc684ea28
commit 6440521f81

View File

@ -18711,16 +18711,9 @@ LABEL_RESTART:
// Create a thread to get a NAT-T IP address if necessary // Create a thread to get a NAT-T IP address if necessary
if (u->GetNatTIpThread == NULL) if (u->GetNatTIpThread == NULL)
{ {
// Create a thread to get a NAT-T IP address if necessary char natt_hostname[MAX_SIZE];
if (u->GetNatTIpThread == NULL) RUDPGetRegisterHostNameByIP(natt_hostname, sizeof(natt_hostname), NULL);
{ u->GetNatTIpThread = NewQueryIpThread(natt_hostname, QUERYIPTHREAD_INTERVAL_LAST_OK, QUERYIPTHREAD_INTERVAL_LAST_NG);
char natt_hostname[MAX_SIZE];
RUDPGetRegisterHostNameByIP(natt_hostname, sizeof(natt_hostname), NULL);
u->GetNatTIpThread = NewQueryIpThread(natt_hostname, QUERYIPTHREAD_INTERVAL_LAST_OK, QUERYIPTHREAD_INTERVAL_LAST_NG);
}
GetQueryIpThreadResult(u->GetNatTIpThread, &nat_t_ip); GetQueryIpThreadResult(u->GetNatTIpThread, &nat_t_ip);
} }
} }