roell@lan.informatik.tu-muenchen.dbp.de (Thomas Roell) (06/11/90)
Cause I liked to use multible other devices with X11R4 I started to add the
xinput extension to a server. But I ran soon into some very strange problems:
1) Before I started adding any stuff to the server, I tried to ran the examples
provided with the mit-tape ( mit/extension/tests/xinput). Compiling two of
them causes problems (some functions missing in libXinput.a):
i) xlist: XFreeDeviceList
ii) xtouch: XFreeDeviceMotionEvents, XFreeDeviceState, XFreeDeviceList
I didn't find these procedures to whole X11R4 tape. Are they generally
missing, or are there allready patches available ? (I'm using patch-
level 9).
2) After adding some code to the server there were some strange faults. But I
should first state, what I've do to the server:
There are two classes of devices primary (core X devices, mouse, keyboard)
and secondary (all other that are not primary). All devices are enabled in
InitInput (primaries: RegisterKeyboardDevice, RegisterPointerDevice,
secondaries: RegisterOtherDevice). The two primaries are selectable by the
user. Depending wether beeing a primary or a secondary device the device
sends appropriate events (mouse for example: ButtonPress if primary,
deviceButtonPress if secondary). All devices that are enabled are queried
for events. (I should say that a mouse is initialized in it's own
deviceProc via InitPointerDevice wether it is primary or secondary).
So far so good. To test this out I used two mice (one primary, one
secondary). All works fine up to this point. xlist found all devices, the
primary devices are working fine. But if I now cause a secondary events by
pressing a button or moving the second mouse, the server dumps core
(memory fault).
Analysing the core I found out that ProcessOtherEvents calls
DeliverFocusedEvent even mousedevices!!! (dix calls this routine only for
keyboard devices) The coredump itself is really caused by
FixUpEventsFromWindow. What am I doing wrong, or is the bug deep in
xinput ?
- Thomas
--
_______________________________________________________________________________
Mail: Thomas Roell (c/o Daniel Hernandez)
Inst. f. Informatik / Technische Universitaet M"unchen
Arcisstr. 21 / 8000 Munich 2 / Fed.Rep. of Germany
E-Mail (domain): roell@lan.informatik.tu-muenchen.dbp.de
UUCP (when above fails): roell@tumult.{uucp | informatik.tu-muenchen.de}
-------------------------------------------------------------------------------