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



On Mon, Mar 08, 1999 at 10:38:22AM -0500, Paul Bunyk wrote:

> What I want to do it to fork my GUI process, in child freopen stdin/stdout
> and switch stderr to a pipe (which in parent process will be printed out
> in a text box) then exec my program. When I do it in straightforward way
> I get "x io" and "lost x sequence" errors,

I'm a newbe myself but have catched up on this list that You have to
exit forked procesess with _exit() insted of exit() cose exit() will
close the gtk session to X.

> especially if I try to 
> call gtk_widget_show(errorDialog) from the child process. 

Don't know if You can do that at all (call gtk funktions from another
proces...

HTH (some) /Lars



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