web/modules/pxt/PXT/ApacheHandler.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
New commits: commit 989f242ba10c27d3c6db93b339944662f826d4e0 Author: Jan Pazdziora jpazdziora@redhat.com Date: Fri Feb 18 09:59:36 2011 +0100
Localize the MYFILE; also use three-parameter open.
diff --git a/web/modules/pxt/PXT/ApacheHandler.pm b/web/modules/pxt/PXT/ApacheHandler.pm index 9388731..7796b0e 100644 --- a/web/modules/pxt/PXT/ApacheHandler.pm +++ b/web/modules/pxt/PXT/ApacheHandler.pm @@ -444,7 +444,8 @@ sub _read_file {
#my $root = $self->document_root();
- if (not open MYFILE, ("$root/$file")) { + local * MYFILE; + if (not open MYFILE, '<', "$root/$file") { Carp::cluck "Couldn't open file: $root/$file ($!)"; return ''; }
commit e8014adc37fbf39b3fbf9aae2f6d2166ec0419c4 Author: Jan Pazdziora jpazdziora@redhat.com Date: Fri Feb 18 09:59:01 2011 +0100
Localize the FH; also use three-parameter open.
diff --git a/web/modules/pxt/PXT/ApacheHandler.pm b/web/modules/pxt/PXT/ApacheHandler.pm index d09f10b..9388731 100644 --- a/web/modules/pxt/PXT/ApacheHandler.pm +++ b/web/modules/pxt/PXT/ApacheHandler.pm @@ -219,8 +219,9 @@ sub load_pxt_file { } }
+ local * FH; unless ($use_cache) { - open FH, ("<" . $filename) or return; + open FH, '<', $filename or return; }
local $/ = undef;
spacewalk-commits@lists.fedorahosted.org