This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libc/11697] New: pt_chown doesn't work when the PTY's gid is already correct


I upgraded from 2.7 to 2.11, and my terminals broke.  I've tracked it down to
pt_chown not doing what it is asked to do.  The git change:

commit 837dea7cf54827d6e43d88a9463bcc10d30472d0
Author: Ulrich Drepper <drepper@redhat.com>
Date:   Mon Jun 15 22:58:21 2009 -0700

is wrong if the PTY has the wrong ownership but the correct group.  That's
because this line:

if (st.st_gid != gid && chown (pty, getuid (), gid) < 0)

will not call chown() to fix the UID if the GID is already correct.  Since the
UID change is an important part of the function of pt_chown, it breaks things. 
I patched my local copy, removing the first clause from the &&, and it now works
for me again.

-- 
           Summary: pt_chown doesn't work when the PTY's gid is already
                    correct
           Product: glibc
           Version: 2.11
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
        AssignedTo: drepper at redhat dot com
        ReportedBy: glibcbugs0000 at cneufeld dot ca
                CC: glibc-bugs at sources dot redhat dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=11697

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]