VirtualBox

Ignore:
Timestamp:
Jun 12, 2020 12:43:02 PM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
138620
Message:

Guest Control: Also implemented a "force" flag for the reboot/shutdown command. bugref:9320

Location:
trunk/src/VBox/Frontends/VBoxManage
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxManage/VBoxManageControlVM.cpp

    r84585 r84814  
    693693
    694694            com::SafeArray<GuestShutdownFlag_T> aShutdownFlags;
    695             aShutdownFlags.resize(1);
    696 
    697695            if (fReboot)
    698696                aShutdownFlags.push_back(GuestShutdownFlag_Reboot);
    699697            else
    700698                aShutdownFlags.push_back(GuestShutdownFlag_PowerOff);
     699
     700            if (   a->argc >= 3
     701                && !strcmp(a->argv[2], "--force"))
     702                aShutdownFlags.push_back(GuestShutdownFlag_Force);
     703
    701704            CHECK_ERROR(pGuest, Shutdown(ComSafeArrayAsInParam(aShutdownFlags)));
    702705            if (FAILED(rc))
  • trunk/src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp

    r84576 r84814  
    834834                     "                            pause|resume|reset|poweroff|savestate|\n"
    835835#ifdef VBOX_WITH_GUEST_CONTROL
    836                      "                            reboot|shutdown|\n"
     836                     "                            reboot|shutdown [--force]|\n"
    837837#endif
    838838                     "                            acpipowerbutton|acpisleepbutton|\n"
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette