Skip to content

Commit 0816fc1

Browse files
null check on TCP fd parameter before set
1 parent 6ec7538 commit 0816fc1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

port/posix/posix_transport_tcp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ int posixTransportTcp_GetConnectFd(posixTransportTcpClientContext *context,
454454
case PTT_STATE_CONNECT_WAIT:
455455
case PTT_STATE_CONNECTED:
456456
ret = WH_ERROR_OK;
457-
if (*out_fd) {
457+
if (out_fd) {
458458
*out_fd = context->connect_fd_p1 - 1;
459459
}
460460
break;

0 commit comments

Comments
 (0)