From 200ba57bbda1b8ec52dfcc9b1259669e51eebca5 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Wed, 21 May 2025 09:00:01 -0400 Subject: [PATCH] MT#62181 tcp: fix fd != -1 handling Change-Id: I1826396701ac12e7870c752bd25df8f331f2d0bd --- core/sip/tcp_trsp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/sip/tcp_trsp.cpp b/core/sip/tcp_trsp.cpp index b37d9192..8db96877 100644 --- a/core/sip/tcp_trsp.cpp +++ b/core/sip/tcp_trsp.cpp @@ -601,7 +601,7 @@ tcp_server_socket::tcp_server_socket(unsigned short if_num) int tcp_server_socket::bind(const string& bind_ip, unsigned short bind_port) { - if(sd){ + if(sd != -1){ WARN("re-binding socket\n"); close(sd); sd = -1;