Bug 38645

Summary: evolution run on a remote machine crashes on my netbook running Ubunto 11.04
Product: xorg Reporter: David Ronis <David.Ronis>
Component: Lib/XiAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED NOTOURBUG QA Contact: Xorg Project Team <xorg-team>
Severity: major    
Priority: medium    
Version: git   
Hardware: Other   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
complete backtrace
none
proposed patch for this problem
none
complete backtrace (sic!) none

Description David Ronis 2011-06-24 09:04:56 UTC
I'm trying to run evolution on my mail hosts (running various versions of slackware) and have the GUI display on my netbook (a gateway, running Ubuntu).   This worked as expected until I upgraded my netbook's Ubuntu  to version 11.04 (from 10.04); now when I run evolution crashes.   This worked before the upgrade and still works if I try to remote display between my slackware boxes.   I've got various version of xorg installed on the latter (up to a fairly recent git/master).   Other programs (e.g., gnumeric) work as expected if I run remotely.

I've reported this problem to the evolution folks at:  

https://bugzilla.gnome.org/show_bug.cgi?id=649345

who said it wasn't their fault.   I then reported it to ubuntu at 

https://bugs.launchpad.net/bugs/781391.  

They've also concluded that it's not their fault either (I'm not sure this is correct, since the change that triggered the problem happened when I upgraded Ubuntu).

There are more details in the earlier bug report
Comment 1 Jeremy Huddleston Sequoia 2011-10-04 23:24:27 UTC
The backtrace from the gnome bug snows that you're crashing in XIFreeDeviceInfo 
which is fairly small and "correct" ... my guess is that the bug is in the 
caller over releasing or a memory smasher at some higher level.  Not a libXi 
bug.
Comment 2 Reinhard Tartler 2012-12-11 12:43:32 UTC
Created attachment 71336 [details] [review]
complete backtrace

I have found a similar crasher to this one in kde4 when using nxagent, an X11 implementation from nomachine.com.

nxagent (probably) does not support the XI extension properly and does return as number of devices "0". kdeinit implicitly assumes that XIQueryDevice always returns a proper XIDeviceInfo info structure that can be freed with XIFreeDeviceInfo. However, this is not the case with nxagent, possibly also not with other Xservers.

Sure, this could also be worked around in ktouchpadenabler_daemon.cpp, but I guess the safer approach would be to add a check for null pointer in libxi.
Comment 3 Reinhard Tartler 2012-12-11 12:44:48 UTC
Created attachment 71337 [details] [review]
proposed patch for this problem
Comment 4 Reinhard Tartler 2012-12-11 12:45:18 UTC
Created attachment 71338 [details]
complete backtrace (sic!)

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.