Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: PERL/Windows file open error

by Laurent_R (Canon)
on Mar 04, 2019 at 15:46 UTC ( #1230850=note: print w/replies, xml ) Need Help??


in reply to PERL/Windows file open error

Hi,

maybe try to change this line:

open ($FH,'<',$fn);
to something like this:
open $FH, '<', $fn or die "Failed to open file $fh $!";
This way, you can ascertain the name of the file you were trying to open and figure out whether there is something wrong with the content of $fh.

Update (15:50 UTC): I see now that you're actually printing the file name right before, so what I suggested is useless. And also that you're using autodie. Never mind.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1230850]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (4)
As of 2020-10-01 05:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If at first I donít succeed, I Ö










    Results (175 votes). Check out past polls.

    Notices?