[Bug 3345] New: sshd freeze when build without HAVE_PSELECT

bugzilla-daemon at mindrot.org bugzilla-daemon at mindrot.org
Tue Sep 7 20:55:09 AEST 2021


https://bugzilla.mindrot.org/show_bug.cgi?id=3345

            Bug ID: 3345
           Summary: sshd freeze when build without HAVE_PSELECT
           Product: Portable OpenSSH
           Version: 8.7p1
          Hardware: Itanium
                OS: Other
            Status: NEW
          Severity: normal
          Priority: P5
         Component: sshd
          Assignee: unassigned-bugs at mindrot.org
          Reporter: yaroslav.kuzmin at vmssoftware.com

In openbsd-compat/bsd-pselect.c file in pselect() function.

Line 196 incorrect call to select() function.
If unmasked !=0 , nfds need +1

   8   if (unmasked) {
   7     pselect_notify_setup();
   6     pselect_notify_prepare(readfds);
   5     nfds = MAX(nfds, notify_pipe[0]);
   4   }
   3 
   2   /* Unmask signals, call select then restore signal mask. */
   1   sigprocmask(SIG_SETMASK, mask, &osig);
 196   ret = select(nfds, readfds, writefds, exceptfds, tvp);
   1   saved_errno = errno;
   2   sigprocmask(SIG_SETMASK, &osig, NULL);
   3 
   4   if (unmasked)
   5     pselect_notify_done(readfds);

-- 
You are receiving this mail because:
You are watching the assignee of the bug.


More information about the openssh-bugs mailing list