Re: [gtk-list] Proper way to fork() a GTK program (to exec() something)



Paul Bunyk <paul@pbunyk.physics.sunysb.edu> writes:

> Are there any rules how should I do that? E.g., can I just use
> exit() my child process (if something goes wrong before exec), or I
> should use gtk_exit()?

As Lars explained, you definitely want to use _exit() in the child, so 
that the atexit handlers don't run and screw up the parent.

Also, you probably cannot do what you intended to do, i.e. directly
call gtk functions from the child process.  The pipe thing should
work, though.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]