Re: Possible bug in 5.8.6: accept/fork/wait/exit ?



james@xxxxxxxxxxxxx wrote:
> Any multi-process/networking gurus here?
>
> I'm trying to write a simple forking HTTP proxy but am having a problem
> when running it with Perl 5.8.6. The program spontaneously exits after
> one or a few connections. The problem does not happen when I use Perl
> 5.6.1.

I also don't see the problem on 5.8.0 or 5.8.3.

....
> shell window. Now, repeat the telnet command over and over. After 1-20
> telnets, the script exits with no message.

That is not surprising, since you don't ask for a message.


> for ( ; $paddr= accept(S_CLIENT, S_LISTEN) ; close S_CLIENT) {

for ( ; $paddr= accept(S_CLIENT, S_LISTEN) or die $!; close S_CLIENT) {

Xho

--
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service $9.95/Month 30GB
.