in reply to Use of uninitialized value in open second time but not first.
#!/usr/bin/perl -w my $output; print "first\n"; open (FH, '>', \$output); print FH "Hello world\n"; close(FH); $output=undef; print "second\n"; open (FH, '>', \$output); print FH "Hello world\n"; close(FH);
Output:
Seems to me like an overzealous action by Perl's warning system but nothing alarming so far.first second Use of uninitialized value in open at o4.pl line 10.
|
|---|