1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

s3: Properly deal with exited winbind children

When a winbind child exits, we need to immediately close the socket. If not,
the next request to that child will be sent to a socket without a listener,
leading to a failed request. This failed request will then trigger a proper
re-init.

This patch avoids the one failed request.

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed May  4 13:32:16 CEST 2011 on sn-devel-104
This commit is contained in:
Volker Lendecke 2011-05-04 12:11:04 +02:00 committed by Volker Lendecke
parent b8eaec6b66
commit d08414b679

View File

@ -510,6 +510,11 @@ void winbind_child_died(pid_t pid)
DLIST_REMOVE(winbindd_children, child);
child->pid = 0;
if (child->sock != -1) {
close(child->sock);
child->sock = -1;
}
}
/* Ensure any negative cache entries with the netbios or realm names are removed. */