Commit a2e25cf4 authored by Philip Withnall's avatar Philip Withnall

socket: Close base socket for a TCP passive socket when closing parent

Otherwise the base socket will leak. Spotted by Vadim Genkin.

https://phabricator.freedesktop.org/T125
parent 6835e7b7
......@@ -176,6 +176,12 @@ socket_close (NiceSocket *sock)
{
TcpPassivePriv *priv = sock->priv;
if (sock->fileno != NULL) {
g_socket_close (sock->fileno, NULL);
g_object_unref (sock->fileno);
sock->fileno = NULL;
}
if (priv->context)
g_main_context_unref (priv->context);
g_hash_table_unref (priv->connections);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment