]> andersk Git - openssh.git/commitdiff
- (dtucker) [auth-pam.c] Check for zero from waitpid() too, which allows
authordtucker <dtucker>
Sun, 11 Jul 2004 06:54:08 +0000 (06:54 +0000)
committerdtucker <dtucker>
Sun, 11 Jul 2004 06:54:08 +0000 (06:54 +0000)
   the monitor to properly clean up the PAM thread (Debian bug #252676).

ChangeLog
auth-pam.c

index 86146b4c34ba1f7900d778583dd7e00eee7e471a..22264583185de5cd0e8a6285c0012038e7aa7ad9 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+20040711
+ - (dtucker) [auth-pam.c] Check for zero from waitpid() too, which allows
+   the monitor to properly clean up the PAM thread (Debian bug #252676).
+
 20040709
  - (tim) [contrib/cygwin/README] add minires-devel requirement. Patch from
    vinschen AT redhat.com
index 76a43a350f28e61ce1ebde1e3f48f00045b9f928..59d20555da1fd7453441a78017952faf7b09f702 100644 (file)
@@ -113,11 +113,11 @@ sshpam_sigchld_handler(int sig)
        if (cleanup_ctxt == NULL)
                return; /* handler called after PAM cleanup, shouldn't happen */
        if (waitpid(cleanup_ctxt->pam_thread, &sshpam_thread_status, WNOHANG)
-            == -1) {
+            <= 0) {
                /* PAM thread has not exitted, privsep slave must have */
                kill(cleanup_ctxt->pam_thread, SIGTERM);
                if (waitpid(cleanup_ctxt->pam_thread, &sshpam_thread_status, 0)
-                   == -1)
+                   <= 0)
                        return; /* could not wait */
        }
        if (WIFSIGNALED(sshpam_thread_status) &&
This page took 0.046858 seconds and 5 git commands to generate.