[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#206141: xdm login fails when .Xauthority cannot be written to



Package: xdm
Version: 4.2.1-9
Severity: important

(I'm running xfree86 4.3.0 on the notebook that I am reporting this from,
but it apply to other machines running 4.2.1-6 and the bug is still in
4.2.1-9.  That is why the version information in the trailer is confusing).

When xdm cannot write to $HOME/.Xauthority, such as when the user is over quota,
it tried to create a .Xauthority file in /tmp and use that.
This breaks due to patch/002_xdm_fixes.diff
In particular openFiles causes a segmentation violation.

Towards the end of the patches openFile are the lines:

+	if (oldp)
+	    *oldp = fopen (name, "r");
+	if (*oldp)
+	    Debug ("open succeeded %s\n", name);

if oldp is NULL, as it will be in this case, the
   if (*oldp)
will dereference a NULL pointer - and BANG.

It needs to be

+	if (oldp)
+	    *oldp = fopen (name, "r");
+	if (oldp && *oldp)
+	    Debug ("open succeeded %s\n", name);

or something similar.

NeilBrown


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux notabene 2.6.0-test3 #14 Sat Aug 16 19:15:12 EST 2003 i686
Locale: LANG=C, LC_CTYPE=C

Versions of packages xdm depends on:
ii  cpp                 4:3.3.1-2            The GNU C preprocessor.
ii  debconf             1.3.8                Debian configuration management sy
ii  libc6               2.3.2-2              GNU C Library: Shared libraries an
ii  libpam0g            0.76-13              Pluggable Authentication Modules l
ii  libxaw7             4.3.0-0ds2.0.0woody2 X Athena widget set library
ii  xbase-clients       4.3.0-0ds2.0.0woody2 miscellaneous X clients
ii  xlibs               4.3.0-0ds2.0.0woody2 X Window System client libraries

-- debconf information excluded





Reply to: