Help for this page

Select Code to Download


  1. or download this
    my $links = new IO::Select();
    $links->add($mcserver);
    $links->add(\*STDIN);
    ...
    while (my @allhandles = $links->select($links, undef, $links) {
    
  2. or download this
    while (my @allhandles = $links->select($links, undef, $links) {
    
  3. or download this
    while (my @allhandles = IO::Select::select($links, undef, $links) {
    
  4. or download this
    if (sysread $handle, $command, 1024) {
    ... do stuff
    } else {
    ... client went away...handle it.
    }