Additional error checking.

This commit is contained in:
Dr. Stephen Henson
2011-07-02 15:57:35 +00:00
parent da5e9871e9
commit eca7358be3
2 changed files with 5 additions and 3 deletions

View File

@@ -49,11 +49,11 @@ while (<IN>)
my ($from, $to);
#rename target temporarily
rename($target, "tmptarg.s") || die "Can't rename $target\n";
rename($target, "tmptarg.s") || die "Can't rename $target";
#edit target
open IN,"tmptarg.s";
open OUT, ">$target";
open(IN,"tmptarg.s") || die "Can't open temporary file";
open(OUT, ">$target") || die "Can't open output file $target";
while (<IN>)
{