From 7b7085742f99ec6300d4bcc420872d8d5bd7fe32 Mon Sep 17 00:00:00 2001 From: chudegao Date: Mon, 22 Jul 2013 06:53:49 +0000 Subject: [PATCH] fix#220182,The node is not rebooted automatically while use new image profile during re-installation process git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.8@17007 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/profilednodes.pm | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/xCAT-server/lib/xcat/plugins/profilednodes.pm b/xCAT-server/lib/xcat/plugins/profilednodes.pm index 97945787c..2492a73df 100644 --- a/xCAT-server/lib/xcat/plugins/profilednodes.pm +++ b/xCAT-server/lib/xcat/plugins/profilednodes.pm @@ -179,14 +179,17 @@ sub parse_args{ } # translate the profile names into real group names in db. - if($argarray[0] eq "networkprofile"){ - $args_dict{$argarray[0]} = "__NetworkProfile_".$argarray[1]; - } elsif ($argarray[0] eq "imageprofile"){ - $args_dict{$argarray[0]} = "__ImageProfile_".$argarray[1]; - } elsif ($argarray[0] eq "hardwareprofile"){ - $args_dict{$argarray[0]} = "__HardwareProfile_".$argarray[1]; - } else{ - $args_dict{$argarray[0]} = $argarray[1]; + if($argarray[1]) + { + if($argarray[0] eq "networkprofile"){ + $args_dict{$argarray[0]} = "__NetworkProfile_".$argarray[1]; + } elsif ($argarray[0] eq "imageprofile"){ + $args_dict{$argarray[0]} = "__ImageProfile_".$argarray[1]; + } elsif ($argarray[0] eq "hardwareprofile"){ + $args_dict{$argarray[0]} = "__HardwareProfile_".$argarray[1]; + } else{ + $args_dict{$argarray[0]} = $argarray[1]; + } } } return undef;