else { while ($line = <>) { print $client $line; } } #### #assuming $server initialized while($child = $server->accept() ) { next if $pid = fork(); #CHILD STUFF exit; #kill the child process }