" Bareword "LOCK_EX" not allowed while "strict subs" in use at student_info_viewer.cgi line 47"
Can someone help me see what I am overlooking?
# Declare the 'working' datahash, then tie it to file my %datahash; my $db = tie %datahash, 'DB_File', $file_to_view, O_RDWR | O_CREAT, 0644 or die "Can't initialize database: $!\n"; my $fd = $db->fd(); # get a file descriptor open DATAFILE, "+<&=$fd" or die "Can't safely open file: $!\n"; flock ( DATAFILE, LOCK_EX ) or die "Unable to acquire exclusive lock: $!. Aborting"; undef $db; # Avoid untie problems
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>