Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

close and autodie on pipes

by apomatix (Novice)
on Jun 29, 2012 at 18:06 UTC ( #979163=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    use strict;
    ...
    close $fh;
    my $status = $? >> 8;
    print "$status\n";
    
  2. or download this
    Hello
    1
    
  3. or download this
    #!/usr/bin/perl
    use strict;
    ...
    close $fh;
    my $status = $? >> 8;
    print "$status\n";
    
  4. or download this
    Hello
    Can't close(GLOB(0x10082a098)) filehandle: '' at test.pl line 7
    
  5. or download this
    use strict;
    use autodie;
    ...
    #close $fh;
    my $status = $? >> 8;
    print "$status\n";
    
  6. or download this
    Hello
    0
    
  7. or download this
    use strict;
    use autodie;
    ...
     close $fh;}
    my $status = $? >> 8;
    print "$status\n";
    
  8. or download this
    Hello
    1
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://979163]
Approved by toolic
Front-paged by MidLifeXis
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2017-01-21 08:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (182 votes). Check out past polls.