--- rat/lonuserstate.pm 2017/09/03 18:52:23 1.153 +++ rat/lonuserstate.pm 2017/11/16 12:44:48 1.154 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Construct and maintain state and binary representation of course for user # -# $Id: lonuserstate.pm,v 1.153 2017/09/03 18:52:23 raeburn Exp $ +# $Id: lonuserstate.pm,v 1.154 2017/11/16 12:44:48 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1209,7 +1209,7 @@ sub readmap { } @cond=('true:normal'); - unless (open(LOCKFILE,">$fn.db.lock")) { + unless (open(LOCKFILE,">","$fn.db.lock")) { # # Most likely a permissions problem on the lockfile or its directory. # @@ -1522,7 +1522,7 @@ sub build_tmp_hashes { # ---------------------------------------------------- Store away initial state { my $cfh; - if (open($cfh,">$fn.state")) { + if (open($cfh,">","$fn.state")) { print $cfh join("\n",@cond); $gotstate = 1; } else { @@ -1559,7 +1559,7 @@ sub evalstate { if (-e $fn) { my @conditions=(); { - open(my $fh,"<$fn"); + open(my $fh,"<",$fn); @conditions=<$fh>; close($fh); }