Changeset 23703 in vbox for trunk/src/VBox/Main/ConsoleImpl.cpp
- Timestamp:
- Oct 12, 2009 3:34:36 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ConsoleImpl.cpp
r23669 r23703 4730 4730 * any error reporting and appropriate state change! */ 4731 4731 4732 if ( mMachineState == MachineState_Saved 4733 || fLiveMigrationTarget) 4732 if (mMachineState == MachineState_Saved) 4734 4733 setMachineState(MachineState_Restoring); 4734 else if (fLiveMigrationTarget) 4735 setMachineState(MachineState_MigratingFrom); 4735 4736 else 4736 4737 setMachineState(MachineState_Starting); … … 4798 4799 mMachineState == MachineState_Starting || 4799 4800 mMachineState == MachineState_Restoring || 4801 mMachineState == MachineState_MigratingFrom || /** @todo LiveMigration ???*/ 4800 4802 mMachineState == MachineState_Stopping, 4801 4803 ("Invalid machine state: %s\n", Global::stringifyMachineState(mMachineState))); … … 4809 4811 * powerUpThread() is calling us on failure, so the VM is already off at 4810 4812 * that point. */ 4811 if (!mVMPoweredOff && 4812 (mMachineState == MachineState_Starting || 4813 mMachineState == MachineState_Restoring)) 4813 if ( !mVMPoweredOff 4814 && ( mMachineState == MachineState_Starting 4815 || mMachineState == MachineState_Restoring 4816 || mMachineState == MachineState_MigratingFrom) 4817 ) 4814 4818 mVMPoweredOff = true; 4815 4819 … … 4819 4823 * inappropriate operations while leaving the lock below, Saving or 4820 4824 * Restoring should be fine too */ 4821 if (mMachineState != MachineState_Saving && 4822 mMachineState != MachineState_Restoring && 4823 mMachineState != MachineState_Stopping) 4825 if ( mMachineState != MachineState_Saving 4826 && mMachineState != MachineState_Restoring 4827 && mMachineState != MachineState_MigratingFrom 4828 && mMachineState != MachineState_Stopping 4829 ) 4824 4830 setMachineState(MachineState_Stopping); 4825 4831 … … 5504 5510 if ( that->mMachineState != MachineState_Stopping 5505 5511 && that->mMachineState != MachineState_Saving 5506 && that->mMachineState != MachineState_Restoring) 5512 && that->mMachineState != MachineState_Restoring 5513 && that->mMachineState != MachineState_MigratingFrom 5514 ) 5507 5515 { 5508 5516 LogFlowFunc(("VM has powered itself off but Console still thinks it is running. Notifying.\n")); … … 5598 5606 that->setMachineState(MachineState_Saved); 5599 5607 break; 5608 case MachineState_MigratingFrom: 5609 /* Migration failed or was cancelled. Back to powered off. */ 5610 that->setMachineState(MachineState_PoweredOff); 5611 break; 5600 5612 } 5601 5613 break; … … 5635 5647 && aOldState == VMSTATE_POWERING_ON) 5636 5648 || ( ( that->mMachineState == MachineState_Restoring 5649 || that->mMachineState == MachineState_MigratingFrom 5637 5650 || that->mMachineState == MachineState_Paused) 5638 5651 && aOldState == VMSTATE_RESUMING)); … … 6828 6841 catch (HRESULT aRC) { rc = aRC; } 6829 6842 6830 if (console->mMachineState == MachineState_Starting || 6831 console->mMachineState == MachineState_Restoring) 6843 if ( console->mMachineState == MachineState_Starting 6844 || console->mMachineState == MachineState_Restoring 6845 || console->mMachineState == MachineState_MigratingFrom 6846 ) 6832 6847 { 6833 6848 /* We are still in the Starting/Restoring state. This means one of:
Note:
See TracChangeset
for help on using the changeset viewer.