in reply to Errors on Parser help
Also, you checked the return value of your first open (although you didn't explicitly specify weather you are opening it for read/write/both which is a good habit to be in):
But you didn't check the return value of the second open:open (DATA, $txtfile)||die "cannot open $txtfile for reading";
You should rewrite both of your open's to use the 3 argument form and always check the return values:open (OUT, ">$txtfile.redo");
open(DATA, ">", $txtfile) or die "File open error: $!";
|
|---|