mirror of
https://github.com/moonlight-stream/GS-IPv6-Forwarder.git
synced 2026-06-22 00:10:54 +00:00
Fix code analysis warnings
This commit is contained in:
+3
-3
@@ -267,7 +267,7 @@ TcpListenerThreadProc(LPVOID Context)
|
|||||||
relayTuple->s2 = targetSocket;
|
relayTuple->s2 = targetSocket;
|
||||||
|
|
||||||
thread = CreateThread(NULL, 0, TcpRelayThreadProc, relayTuple, 0, NULL);
|
thread = CreateThread(NULL, 0, TcpRelayThreadProc, relayTuple, 0, NULL);
|
||||||
if (thread == INVALID_HANDLE_VALUE) {
|
if (thread == NULL) {
|
||||||
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
||||||
closesocket(acceptedSocket);
|
closesocket(acceptedSocket);
|
||||||
closesocket(targetSocket);
|
closesocket(targetSocket);
|
||||||
@@ -318,7 +318,7 @@ int StartTcpRelay(unsigned short Port)
|
|||||||
tuple->port = Port;
|
tuple->port = Port;
|
||||||
|
|
||||||
thread = CreateThread(NULL, 0, TcpListenerThreadProc, tuple, 0, NULL);
|
thread = CreateThread(NULL, 0, TcpListenerThreadProc, tuple, 0, NULL);
|
||||||
if (thread == INVALID_HANDLE_VALUE) {
|
if (thread == NULL) {
|
||||||
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
||||||
return GetLastError();
|
return GetLastError();
|
||||||
}
|
}
|
||||||
@@ -455,7 +455,7 @@ int StartUdpRelay(unsigned short Port)
|
|||||||
tuple->port = Port;
|
tuple->port = Port;
|
||||||
|
|
||||||
thread = CreateThread(NULL, 0, UdpRelayThreadProc, tuple, 0, NULL);
|
thread = CreateThread(NULL, 0, UdpRelayThreadProc, tuple, 0, NULL);
|
||||||
if (thread == INVALID_HANDLE_VALUE) {
|
if (thread == NULL) {
|
||||||
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
fprintf(stderr, "CreateThread() failed: %d\n", GetLastError());
|
||||||
return GetLastError();
|
return GetLastError();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user