Changeset 1251 for trunk/utils

Show
Ignore:
Timestamp:
01/03/09 02:35:31 (15 months ago)
Author:
dormando
Message:

added noreplwait in the wrong place :(

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/utils/mogtool

    r1240 r1251  
    979979    # verify replication and chunks 
    980980    my %paths; # { chunknum => [ path, path, path ... ] } 
    981     my %still_need = $opts{noreplwait} ? () : ( %chunkinfo ); 
     981    my %still_need = ( %chunkinfo ); 
    982982    while (%still_need) { 
    983         print "Replicating (disable with --noreplwait): " . join(' ', sort { $a <=> $b } keys %still_need) . "\n"; 
     983        print "Replicating: " . join(' ', sort { $a <=> $b } keys %still_need) . "\n"; 
    984984        sleep 1; # give things time to replicate some 
    985985 
     
    10231023 
    10241024                # now make sure %paths contains at least 2 verified 
    1025                 next unless scalar(@{$paths{$num} || []}) >= 2; 
     1025                next if scalar(@{$paths{$num} || []}) < 2 && !$opts{noreplwait}; 
    10261026                delete $still_need{$num}; 
    10271027            }