Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
0.13.0, 0.14.0, 0.14.1
-
None
Description
In "thrift_server_socket_listen" function, after the socket is created, the exception branch does not have a close socket.
gboolean
thrift_server_socket_listen (ThriftServerTransport *transport, GError **error)
{
int enabled = 1; /* for setsockopt() */
ThriftServerSocket *tsocket = THRIFT_SERVER_SOCKET (transport);
const int socket_domain = tsocket->path ? PF_UNIX : AF_INET;
/* create a socket */
if ((tsocket->sd = socket (socket_domain, SOCK_STREAM, 0)) == -1)
if (setsockopt(tsocket->sd, SOL_SOCKET, SO_REUSEADDR, &enabled,
sizeof(enabled)) == -1)
......
Attachments
Issue Links
- links to