1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-08 05:57:51 +03:00

s3:ctdbd_conn: make sure we destroy tevent_fd before closing the socket

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11316

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
(cherry picked from commit 70dbba96e311449575f571db68710584fc991234)
This commit is contained in:
Stefan Metzmacher 2015-10-05 15:57:42 +02:00 committed by Karolin Seeger
parent f1ed825175
commit 5dceb51442

View File

@ -421,7 +421,11 @@ static int ctdb_read_req(struct ctdbd_connection *conn, uint32_t reqid,
static int ctdbd_connection_destructor(struct ctdbd_connection *c)
{
close(c->fd);
TALLOC_FREE(c->fde);
if (c->fd != -1) {
close(c->fd);
c->fd = -1;
}
return 0;
}
/*