This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Adjust array index in FileCache.pm.
authorbbucklan@jpl-devvax.jpl.nasa.gov <bbucklan@jpl-devvax.jpl.nasa.gov>
Tue, 15 Jun 2004 16:55:22 +0000 (16:55 +0000)
committerMarcus Holland-Moritz <mhx-perl@gmx.net>
Tue, 22 Jun 2004 21:00:10 +0000 (21:00 +0000)
Subject: [perl #30291] Use of uninitialized value (array index reference) in FileCache.pm module at line 140
From: bbucklan@jpl-devvax.jpl.nasa.gov (via RT) <perlbug-followup@perl.org>
Message-ID: <rt-3.0.9-30291-90552.18.5392299690759@perl.org>

p4raw-id: //depot/perl@22971

lib/FileCache.pm

index 2db9cbe..b1a30de 100644 (file)
@@ -138,7 +138,7 @@ sub cacheout {
       ( $mode !~ /^\s*(?:>>|\+?>|\+?<|\|\-|)|\-\|\s*$/ );
 
     # Mode changed?
-    if( $isopen{$file} && ($mode||'>') ne $isopen{$file}->[2] ){
+    if( $isopen{$file} && ($mode||'>') ne $isopen{$file}->[1] ){
       &cacheout_close($file, 1);
     }