diff --git a/source/winbindd/winbindd_dual.c b/source/winbindd/winbindd_dual.c index f71eec5..88121d2 100644 --- a/source/winbindd/winbindd_dual.c +++ b/source/winbindd/winbindd_dual.c @@ -982,9 +982,6 @@ static bool fork_domain_child(struct winbindd_child *child) ZERO_STRUCT(state); state.pid = sys_getpid(); - /* Stop zombies */ - CatchChild(); - child->pid = sys_fork(); if (child->pid == -1) { @@ -1006,6 +1003,9 @@ static bool fork_domain_child(struct winbindd_child *child) /* Child */ + /* Stop zombies in children */ + CatchChild(); + state.sock = fdpair[0]; close(fdpair[1]);