VirtualBox

Changeset 45829 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Apr 30, 2013 10:10:37 AM (12 years ago)
Author:
vboxsync
Message:

Don't panic on bad state and ignore assertions and other error conditions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR0/VMMR0.cpp

    r45749 r45829  
    768768                    AssertRC(rc2);
    769769
    770                     VMCPU_ASSERT_STATE(pVCpu, VMCPUSTATE_STARTED_HM);
     770                    if (RT_UNLIKELY(   VMCPU_GET_STATE(pVCpu) != VMCPUSTATE_STARTED_HM
     771                                    && RT_SUCCESS_NP(rc)  && rc !=  VINF_VMM_CALL_HOST ))
     772                    {
     773                        /* Manual assert as normal assertions are going to crash in this case. */
     774                        pVM->vmm.s.szRing0AssertMsg1[0] = '\0';
     775                        RTStrPrintf(pVM->vmm.s.szRing0AssertMsg2, sizeof(pVM->vmm.s.szRing0AssertMsg2),
     776                                    "Got VMCPU state %d expected %d.\n", VMCPU_GET_STATE(pVCpu), VMCPUSTATE_STARTED_HM);
     777                        rc = VERR_VMM_WRONG_HM_VMCPU_STATE;
     778                    }
    771779                    VMCPU_SET_STATE(pVCpu, VMCPUSTATE_STARTED);
    772780                }
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