After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 562977 - gsd-mouse-manager should check for XInput server support
gsd-mouse-manager should check for XInput server support
Status: RESOLVED FIXED
Product: gnome-settings-daemon
Classification: Core
Component: plugins
unspecified
Other All
: Normal critical
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
: 573524 577136 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2008-12-02 14:40 UTC by Rémi Cardona
Modified: 2009-04-05 08:55 UTC
See Also:
GNOME target: ---
GNOME version: 2.23/2.24


Attachments
check for server-side XInput support in gsd-mouse-manager.c (667 bytes, patch)
2008-12-02 14:44 UTC, Rémi Cardona
none Details | Review
better fix? (721 bytes, patch)
2008-12-02 17:21 UTC, Jens Granseuer
committed Details | Review

Description Rémi Cardona 2008-12-02 14:40:58 UTC
Steps to reproduce:
1. launch a gnome-session on an Xserver where XInput is unavailable

I've only tested with g-s-d 2.24.1 but there's no reason for 2.25.x not to have this bug either.

Simple patch to follow.

Stack trace:
System: Linux 2.6.27-gentoo-r2 #1 SMP PREEMPT Fri Oct 31 11:04:41 CET 2008 x86_64
X Vendor: The X.Org Group
X Vendor Release: 6600
Selinux: No
Accessibility: Disabled
GTK+ Theme: Clearlooks
Icon Theme: gnome

Memory status: size: 222928896 vsize: 222928896 resident: 7847936 share: 5742592 rss: 7847936 rss_rlim: 18446744073709551615
CPU usage: start_time: 1228152690 rtime: 4 utime: 3 stime: 1 cutime:0 cstime: 0 timeout: 0 it_real_value: 0 frequency: 100

Backtrace was generated from '/usr/libexec/gnome-settings-daemon'

[?1034h[Thread debugging using libthread_db enabled]
[New Thread 0x7fd400b766f0 (LWP 3131)]
[New Thread 0x42203950 (LWP 3133)]
0x00007fd3ff80a54f in __libc_waitpid (pid=3137, stat_loc=0x7fff08cbe1b0, 
    options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:41
	in ../sysdeps/unix/sysv/linux/waitpid.c

Thread 1 (Thread 0x7fd400b766f0 (LWP 3131))

  • #0 __libc_waitpid
    at ../sysdeps/unix/sysv/linux/waitpid.c line 41
  • #1 IA__g_spawn_sync
    at gspawn.c line 382
  • #2 IA__g_spawn_command_line_sync
    at gspawn.c line 694
  • #3 check_if_gdb
    at gnome-breakpad.cc line 223
  • #4 bugbuddy_segv_handle
    at gnome-breakpad.cc line 84
  • #5 <signal handler called>
  • #6 _XiGetDevicePresenceNotifyEvent
    at XExtInt.c line 265
  • #7 gsd_mouse_manager_start
    at gsd-mouse-manager.c line 335
  • #8 impl_activate
    at gsd-mouse-plugin.c line 78
  • #9 gnome_settings_plugin_info_activate
    at gnome-settings-plugin-info.c line 506
  • #10 maybe_activate_plugin
    at gnome-settings-manager.c line 93
  • #11 IA__g_slist_foreach
    at gslist.c line 743
  • #12 gnome_settings_manager_start
    at gnome-settings-manager.c line 271
  • #13 main
    at main.c line 312


----------- .xsession-errors (29 sec old) ---------------------
/etc/X11/gdm/Xsession: Beginning session setup...
/etc/X11/gdm/Xsession: Setup done, will execute: /usr/bin/seahorse-agent --execute /home/remi/.xsession
metisse-xsession:  geom: 1920x1200
dbus-daemon(1586): Opération non permise
--------------------------------------------------

Other information:
Comment 1 Rémi Cardona 2008-12-02 14:44:43 UTC
Created attachment 123797 [details] [review]
check for server-side XInput support in gsd-mouse-manager.c

Patch fixes g-s-d crash with current Xmetisse, which doesn't support XInput.

This patch was adapted from X's "xinput" utility : http://cgit.freedesktop.org/xorg/app/xinput/tree/src/xinput.c#n130

Thanks
Comment 2 Jens Granseuer 2008-12-02 17:21:21 UTC
Created attachment 123812 [details] [review]
better fix?

Thanks for the patch. However, it breaks with non-C99 compilers and introduces a memory leak, so how about this one instead?
Comment 3 Rémi Cardona 2008-12-04 10:37:46 UTC
Indeed, yours is much better and works just as well :)

Thanks
Comment 4 Jens Granseuer 2008-12-04 17:36:44 UTC
2008-12-04  Jens Granseuer  <...>

        * plugins/mouse/gsd-mouse-manager.c: (set_devicepresence_handler):
        fix crash with X servers that don't provide XInput (bug #562977)
Comment 5 Rémi Cardona 2008-12-04 18:30:39 UTC
Thanks :)
Comment 6 Jens Granseuer 2009-01-28 19:36:10 UTC
*** Bug 569567 has been marked as a duplicate of this bug. ***
Comment 7 Jens Granseuer 2009-03-29 17:34:36 UTC
*** Bug 577136 has been marked as a duplicate of this bug. ***
Comment 8 Jens Granseuer 2009-04-05 08:55:39 UTC
*** Bug 573524 has been marked as a duplicate of this bug. ***