[Bug 1345] New: closefromtest fails, sometimes

bugzilla-daemon at bugzilla.mindrot.org bugzilla-daemon at bugzilla.mindrot.org
Wed Jul 25 12:07:23 EST 2007


http://bugzilla.mindrot.org/show_bug.cgi?id=1345

           Summary: closefromtest fails, sometimes
           Product: Portable OpenSSH
           Version: 4.6p1
          Platform: amd64
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Miscellaneous
        AssignedTo: bitbucket at mindrot.org
        ReportedBy: David.Leonard at quest.com


sometimes opebsd-compat/regress/closefromtest fails with
   closefrom: closed descriptors it should not have
(On Red Hat EL 3 x86_64)

This is because /dev/null is not being opened for read properly.

--- openssh/openbsd-compat/regress/closefromtest.c      (revision 160)
+++ openssh/openbsd-compat/regress/closefromtest.c      (working copy)
@@ -38,7 +38,7 @@
        char buf[512];

        for (i = 0; i < NUM_OPENS; i++)
-               if ((fds[i] = open("/dev/null", "r")) == -1)
+               if ((fds[i] = open("/dev/null", O_RDONLY)) == -1)
                        exit(0);        /* can't test */
        max = i - 1;


-- 
Configure bugmail: http://bugzilla.mindrot.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.


More information about the openssh-bugs mailing list