use strict; use warnings; { open my $fh, 'ls /usr |'; } warn "End\n"; __END__ ls: write error End