[xorg-bugzilla-noise] [Bug 808] New: Xt: XtAppAddInput additional
input sometimes ignored in multi-threaded application
bugzilla-daemon at pdx.freedesktop.org
bugzilla-daemon at pdx.freedesktop.org
Tue Jun 29 06:24:24 PDT 2004
Please do not reply to this email: if you want to comment on the bug, go to
the URL shown below and enter your comments there.
http://freedesktop.org/bugzilla/show_bug.cgi?id=808
Summary: Xt: XtAppAddInput additional input sometimes ignored in
multi-threaded application
Product: xorg
Version: unspecified
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Lib/Xt
AssignedTo: xorg-bugzilla-noise at freedesktop.org
ReportedBy: luik at orthogon.de
The X Toolkit does not call the callback function registered with
XtAppAddInput when there is some input pending on the registered file
descriptor, unless an X event has recently been processed. This can
easily been reproduced with the attached test program.
The program consists of three threads:
- main thread: initialization, makes a pipe, registers the pipe[0] fd
as additional input, creates two other threads and runs the X Toolkit
main loop (XtAppNextEvent and XtDispatchEvent).
- WorkThread: endless loop, which calls XQueryTree and then sleeps for
three seconds.
- SignalWaiterThread: handles SIGINT signal using sigwait(), and
writes to pipe[1] when a signal has arrived.
When SIGINT is catched, the input callback for pipe[0] should be
called, but most of the time, it is not. You can enforce the callback
to be called by generating an X event, e.g. by using the command
"xmodmap -e 'pointer = default'".
--
Configure bugmail: http://freedesktop.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the xorg-bugzilla-noise
mailing list