Bug 12291 - Crash when leaving Xserver 1.3.99
Summary: Crash when leaving Xserver 1.3.99
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Server/General (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: Xorg Project Team
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
: 12389 (view as bug list)
Depends on:
Blocks: xorg-7.3
  Show dependency treegraph
 
Reported: 2007-09-05 11:18 UTC by Brice Goglin
Modified: 2007-09-20 17:36 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Check whether fd == -1 before doing stuff in RemoveGeneralSocket (438 bytes, patch)
2007-09-05 11:19 UTC, Brice Goglin
no flags Details | Splinter Review
check for fd == -1 before calling RemoveGeneralSocket (977 bytes, patch)
2007-09-06 13:25 UTC, Julien Cristau
no flags Details | Splinter Review

Description Brice Goglin 2007-09-05 11:18:19 UTC
With Xserver 1.3.99.0 (or .2), run 'startx /usr/bin/xterm' and then hit <ctrl-d> in the terminal. X will try to exit, but fail to restore the VT console, because it crashes. The backtrace is not always the same, sometimes in RemoveGeneralSocket, sometimes in ResetPicturePrivateIndex, FreeScreenSaverTimer, ... whatever.

I talked to daniels on IRC who told me the fix was just to test whether fd is -1 is RemoveGeneralSocket. So I applied the following patch and couldn't get the crash to occur anymore.

Brice
Comment 1 Brice Goglin 2007-09-05 11:19:33 UTC
Created attachment 11436 [details] [review]
Check whether fd == -1 before doing stuff in RemoveGeneralSocket
Comment 2 Julien Cristau 2007-09-06 13:25:11 UTC
Created attachment 11453 [details] [review]
check for fd == -1 before calling RemoveGeneralSocket

The consensus on irc seemed to be that the check for fd == -1 should be done in dbus-core.
Comment 3 Julien Cristau 2007-09-11 02:29:42 UTC
*** Bug 12389 has been marked as a duplicate of this bug. ***
Comment 4 Julien Cristau 2007-09-20 17:36:09 UTC
Fixed on master:
commit 3a965fdadccea7beff09a28c9c0ef4b4975eae38
Author: Aaron Plattner <aplattner@nvidia.com>
Date:   Thu Sep 20 16:22:24 2007 -0700

    Don't segfault on shutdown if we never managed to connect to dbus.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.