"So i should check to make sure that the value is numeric before passing it to seek"
You can, yes. Doing it this way will allow you to handle the error yourself:
my $offset = 'blah'; if ($offset =~ /^[0-9]+$/){ seek $fh, $offset, 0; } else { die "offset needs to be numeric"; }
In reply to Re^3: perl not going to error path
by stevieb
in thread perl not going to error path
by gupr1980
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |