Talk:whilend
Add topicAppearance
Latest comment: 12 years ago by AnWulf
It is also a programming comman in Perl:
while (1) {
while(<STDIN>) { print $sock $_; # send parent's command/data to daemon last if /^$EOF$/; } my(@data) = ( ); $SIG{ALRM} = \&timeout; # reset handler alarm 60; while (<$sock>) { push @data, $_; # accumulate command's reply last if /^$EOF$/; } alarm 0; print (/^$EOF$/ ? @data : "4 Daemon Failure\n$EOF\n");
} # whilend --AnWulf ... Ferþu Hal! 11:45, 28 December 2011 (UTC)