for my $handle ( $sel->can_read(0) ) { if( $handle == $sock ) { # do accepts here... } elsif( $handle == $client_sock ) { # do sysreads here... } }