in reply to Re: Re: thread:shared
in thread thread:shared

Hi, I think I've found the solution.

Eliminate this from the while: @chat" !~ /$ID\s$kill/ and place it right below the cond_wait:
while( 1 ) { lock(@chat); cond_wait(@chat); last unless ( "@chat" !~ /$ID\s$kill/ ); lock($Elm); ...

This way even the last 'chatter' deletes his Writer.

But still I don't really understand what is happening,
carl

Replies are listed 'Best First'.
Re: Re: Re: Re: thread:shared
by Anonymous Monk on Dec 16, 2003 at 17:18 UTC
    Well, if you are going to play with it, please kill the client and reconnect several times.
    After doing this the chat server suddenly crashes with a memory access error.

    Any Ideas?

    carl