1
0
mirror of https://github.com/Ylianst/MeshCommander synced 2025-12-06 06:03:20 +00:00

Add extra check if ChangeBootOrder unsuccessful

This commit is contained in:
jsastriawan
2020-08-05 13:16:51 -07:00
parent ea9fb68287
commit 634f6835c7
2 changed files with 1599 additions and 1185 deletions

View File

@@ -10442,6 +10442,10 @@
// Set the boot order to null, this is needed for some AMT versions that don't clear this automatically.
amtstack.CIM_BootConfigSetting_ChangeBootOrder(null, function (stack, name, response, status) {
if (status != 200) { messagebox("Power Action", format("PUT CIM_BootConfigSetting_ChangeBootOrder, Error #{0}", status) + ((response.Header && response.Header.WsmanError) ? (', ' + response.Header.WsmanError) : '')); return; }
if (response.Body.ReturnValue!=0) {
messagebox("Change Boot Order", "Change Boot Order returns "+ response.Body.ReturnValueStr);
return;
}
amtstack.Put('AMT_BootSettingData', r, powerActionResponse2, 0, 1);
}, 0, 1);
}
@@ -10490,6 +10494,11 @@
function powerActionResponse3(stack, name, response, status) {
console.log('powerActionResponse3(' + name + ',' + response + ',' + status + ')');
if (errcheck(status, stack)) return;
if (response.Body.ReturnValue!=0) {
messagebox("Change Boot Order", "Change Boot Order returns "+ response.Body.ReturnValueStr);
return;
}
//console.log("Performing Power State Change...");
statusbox("Power Action", "Performing power action...");
var action = d5actionSelect.value;

File diff suppressed because one or more lines are too long