From dfe3656113046ca886ac35d25a3459e007701297 Mon Sep 17 00:00:00 2001 From: zhanx Date: Tue, 7 Apr 2009 10:03:58 +0000 Subject: [PATCH] Fix a problem in sub toIP, which can cause xcat commands report 'Cannot resolve ' occasionally git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@3110 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/Utils.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/perl-xCAT/xCAT/Utils.pm b/perl-xCAT/xCAT/Utils.pm index 153469b96..7a03656ad 100644 --- a/perl-xCAT/xCAT/Utils.pm +++ b/perl-xCAT/xCAT/Utils.pm @@ -2772,6 +2772,7 @@ sub toIP { return ([0, $_[0]]); } + $!=undef; my $packed_ip = gethostbyname($_[0]); if (!$packed_ip or $!) {