fix defect #4613 [DEV] rhels7.0 provisioning complains !dracut-cmdline[78]: Warning: 'ksdevice=<MAC>' is deprecated. Using BOOTIF=01-00-21-5e-a6-3d-d7 instead!
This commit is contained in:
parent
254f7b7b43
commit
89f58e514a
11
perl-xCAT/xCAT/Utils.pm
Executable file → Normal file
11
perl-xCAT/xCAT/Utils.pm
Executable file → Normal file
@ -3596,6 +3596,8 @@ sub version_cmp {
|
||||
$ver_a = shift;
|
||||
}
|
||||
my $ver_b = shift;
|
||||
$ver_a =~ s/([-.]0+)+$//;
|
||||
$ver_b =~ s/([-.]0+)+$//;
|
||||
my @array_a = ($ver_a =~ /([-.]|\d+|[^-.\d]+)/g);
|
||||
my @array_b = ($ver_b =~ /([-.]|\d+|[^-.\d]+)/g);
|
||||
|
||||
@ -3620,9 +3622,12 @@ sub version_cmp {
|
||||
} elsif ( $b eq '.' ) {
|
||||
return 1;
|
||||
} elsif ($a =~ /^\d+$/ and $b =~ /^\d+$/) {
|
||||
if ($a =~ /^0/ || $b =~ /^0/) {
|
||||
return ($a cmp $b);
|
||||
} else {
|
||||
# if ($a =~ /^0/ || $b =~ /^0/) {
|
||||
# return ($a cmp $b);
|
||||
# } else {
|
||||
# return ($a <=> $b);
|
||||
# }
|
||||
if($a != $b ){
|
||||
return ($a <=> $b);
|
||||
}
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user