I use g_child_watch_source_new() to get notified when a spawned process exits. It works as expected, but if I ever need to stop taking care of it, this is, the parent process doesn't need to check if the child process is still being executed, I see that I cannot detach it from the main context properly with g_source_destroy(): the GSource still seems to be valid after that, and valgrind reports a FD leak for each Child Watch source that didn't get fired up when parent process exits.
So, is there a safe and clean way to remove those Child Watch sources from the main context?
Thus, even if we do the g_source_destroy() for that GSource to detach it from the main context, the thread will still be there stuck in the blocking read() in the pipe, at least until the child process exits.
Then the answer would be "no" to my question, right?
Cheers,
-Aleksander
_______________________________________________ gtk-list mailing list gtk-list@xxxxxxxxx http://mail.gnome.org/mailman/listinfo/gtk-list