diff options
author | Adam Tkac <vonsch@gmail.com> | 2009-02-23 09:28:26 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-02-23 18:54:56 +1000 |
commit | 1df6716281579e2937743d840ab1079343c503ac (patch) | |
tree | 185c592626844e626e101a96242bf7f8fb278c3e | |
parent | a50c40be1f28467bcef7dc71fab54ebdddacffdf (diff) |
xfree86: don't try to UnInit virtual devices in DIDR. (#20087)
DeleteInputDeviceRequest function doesn't handle "virtual" devices well.
TightVNC libvnc.so module to X (which makes bare Xorg VNC capable) uses such
kind of devices.
Bare Xvnc (it is something like Xvfb) simply uses AddInputDevice &
RegisterDevice functions. Xvnc uses DeleteInputDeviceRequest from Xi/stubs.c
so everything works fine (now I see that DeleteInputDeviceRequest in
Xi/stubs.c should call RemoveDevice function, shouldn't it? :) )
Situation is quite different when you use libvnc.so module. It uses same
schema as Xvnc, so it simply calls AddInputDevice & RegisterDevice. Thus
device is created correctly. When server is terminated it calls
DeleteInputDeviceRequest (now from hw/xfree86/common/xf86Xinput.c) for each
device. Here is the difference - Xvnc calls DeleteInputDeviceRequest from
Xi/stubs.c as I wrote above. Thus Xorg gets sigsegv because "VNC" devices
don't have real input driver.
X.Org Bug 20087 <http://bugs.freedesktop.org/show_bug.cgi?id=20087>
[This isn't really a fix (libVNC should behave correctly) but not crashing the
server sounds like an improvement.]
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | hw/xfree86/common/xf86Xinput.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/xfree86/common/xf86Xinput.c b/hw/xfree86/common/xf86Xinput.c index 59b616cb8..df1ecb913 100644 --- a/hw/xfree86/common/xf86Xinput.c +++ b/hw/xfree86/common/xf86Xinput.c @@ -722,3 +722,3 @@ DeleteInputDeviceRequest(DeviceIntPtr pDev) - if (!isMaster) + if (!isMaster && pInfo != NULL) { |