>it's not related with threads, but it invokes a fork for a server
>process (a main control only, doesn't do mixing stuffs).
>it looks like there is something wrong with this together with xmms.
>i've seen that Xlib got a spurious async.
>magically enough, the attached patch seems to fix.

>From http://www.gtk.org/faq/#AEN477

----------------------------------------------------------------------
5.5. Why does this strange 'x io error' occur when I fork() in my GTK+ app?
Why does this strange 'x io error' occur when I fork() in my GTK+ app?

This is not really a GTK+ problem, and the problem is not related to
fork() either. If the 'x io error' occurs then you probably use the
exit() function in order to exit from the child process.

When GDK opens an X display, it creates a socket file descriptor. When
you use the exit() function, you implicitly close all the open file
descriptors, and the underlying X library really doesn't like this.

The right function to use here is _exit().

Erik Mouw contributed the following code example to illustrate
handling fork() and exit().
----------------------------------------------------------------------


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
_______________________________________________
Alsa-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/alsa-devel

Reply via email to