Changeset 299

Show
Ignore:
Timestamp:
02/10/2007 08:06:09 PM
Author:
luedi
Message:

_get_valid_path can be called without a version number. Protect unitialized value warnings.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/script/Vss2Svn/ActionHandler.pm

    r298 r299  
    11321132    my($self, $physname, $parentphys, $version) = @_; 
    11331133     
     1134    my $physinfo = $gPhysInfo{$physname}; 
     1135    if (!defined $physinfo) { 
     1136        return undef; 
     1137    } 
     1138 
     1139    if (!defined $version) { 
     1140        $version = $physinfo->{last_version}; 
     1141    } 
     1142 
    11341143    # 0.) If the version we are looking for is prior to the first version of this 
    11351144    #     item (e.g in a branch / Pin situation), we need to check the ancestor 
    1136     my $physinfo = $gPhysInfo{$physname}; 
    11371145    if (defined $physinfo && 
    11381146        $version < $physinfo->{first_version}) { 
     
    11651173        return undef; 
    11661174    } 
    1167  
    1168     if (!defined $version) { 
    1169         $version = $physinfo->{last_version}; 
    1170     } 
    1171      
    11721175    # 1. check the parent requested, if there was an item name for this version 
    11731176    #    we can use this item name, since it was valid in that time 

PumaCode.org recommends CVSDude for fast, professional Subversion and Trac hosting:

CVSDude.com

These ads are automatically generated by Google. Revenue from these ads helps to pay for hosting this site; however, these ads do not constitute an endorsement by PumaCode.org.