Changeset 28189

Show
Ignore:
Timestamp:
30.08.2013 09:06:56 (6 years ago)
Author:
jmt12
Message:

Replace the newer (and faster) while(@file) loop with the older (and more reliable) foreach() loop

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • gs2-extensions/parallel-building/trunk/src/bin/script/generate_gantt.pl

    r28188 r28189  
    44use strict; 
    55use warnings; 
    6 use 5.012; # so readdir assigns to $_ in a lone while test 
    76 
    87# Modules 
     
    8382  # We also recursively search for other directories containing timing.csv's 
    8483  opendir(my $dh, $dir) or &printError('Failed to open directory for reading: ' . $dir); 
    85   while (readdir($dh)) 
    86   { 
    87     my $file = $_; 
     84  my @files = readdir($dh); 
     85  foreach my $file (@files) 
     86  { 
    8887    if ($file !~ /^\./) 
    8988    {