Re: [Speedycgi-users] My non-CGI script hangs after exit()
Brought to you by:
samh
|
From: Sam H. <sa...@da...> - 2002-03-30 17:10:28
|
I tried a one-line "exit" program and it doesn't hang, so there's probably
something else going on.
One possible cause is that you forked off another process that still has
stdin or stdout open. For example, this program will hang under speedy
but not under perl:
system("sleep 300 &");
exit();
A workaround would be:
if (fork == 0) {
close(STDOUT);
close(STDIN);
close(STDERR);
exec("sleep 300");
}
exit();
Currently the frontend exits only when all communication on the stdio
sockets ceases.
>
> I am using speedy with a non-CGI script, and it is hanging after the
> exit().
>
> has anyone else encountered this?
>
> thanks, mark.
>
> _______________________________________________
> Speedycgi-users mailing list
> Spe...@li...
> https://lists.sourceforge.net/lists/listinfo/speedycgi-users
|