2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-24 15:05:36 +00:00

Fix the calculation error for conserver version number

This patch fix the error while calculating the version number.
Use int instead of ord to convert string to integer.

fix-issue: #3286
This commit is contained in:
chenglch
2017-06-20 10:12:54 +08:00
parent a8d731bd80
commit a6696f7fde

View File

@ -638,7 +638,7 @@ sub calc_conserver_version
{
my $ver_str = shift;
my @vers = split(/\./, $ver_str);
return ord($vers[2]) + ord($vers[1]) * 10000 + ord($vers[0]) * 100000000;
return int($vers[2]) + int($vers[1]) * 10000 + int($vers[0]) * 100000000;
}