2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-29 17:23:08 +00:00

Initialize variables to Unknown in loop incase BMC doesn't respond with any values

This commit is contained in:
Victor Hu 2017-11-15 23:00:45 -05:00
parent 9f6c4310fb
commit a88903e0e1

View File

@ -2444,6 +2444,11 @@ sub rflash_response {
xCAT::SvrUtils::sendmsg("-" x 55, $callback, $node);
foreach my $key_url (keys %{$response_info->{data}}) {
# Initialize values to Unknown for each loop, incase they are not defined in the BMC
$update_activation = "Unknown";
$update_purpose = "Unknown";
$update_version = "Unknown";
my %content = %{ ${ $response_info->{data} }{$key_url} };
$update_id = (split(/\//, $key_url))[ -1 ];