From a6696f7fde0e4243f07911842082c0f957767fe6 Mon Sep 17 00:00:00 2001 From: chenglch Date: Tue, 20 Jun 2017 10:12:54 +0800 Subject: [PATCH] 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 --- perl-xCAT/xCAT/Utils.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/perl-xCAT/xCAT/Utils.pm b/perl-xCAT/xCAT/Utils.pm index 1dde56d16..ea107f482 100644 --- a/perl-xCAT/xCAT/Utils.pm +++ b/perl-xCAT/xCAT/Utils.pm @@ -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; }