VirtualBox

Changeset 60626 in vbox


Ignore:
Timestamp:
Apr 21, 2016 1:23:41 PM (8 years ago)
Author:
vboxsync
Message:

dbgf.cpp: turned annoying assertion into non-asserting check.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR3/DBGF.cpp

    r59207 r60626  
    12181218    VM_ASSERT_VALID_EXT_RETURN(pVM, VERR_INVALID_VM_HANDLE);
    12191219    AssertReturn(pVM->dbgf.s.fAttached, VERR_DBGF_NOT_ATTACHED);
    1220     AssertReturn(RTSemPongIsSpeaker(&pVM->dbgf.s.PingPong), VERR_SEM_OUT_OF_TURN);
     1220    if (RT_LIKELY(RTSemPongIsSpeaker(&pVM->dbgf.s.PingPong)))
     1221    { /* likely */ }
     1222    else
     1223        return VERR_SEM_OUT_OF_TURN;
    12211224
    12221225    /*
     
    12491252    PVM pVM = pUVM->pVM;
    12501253    VM_ASSERT_VALID_EXT_RETURN(pVM, VERR_INVALID_VM_HANDLE);
     1254    AssertReturn(idCpu < pVM->cCpus, VERR_INVALID_PARAMETER);
    12511255    AssertReturn(pVM->dbgf.s.fAttached, VERR_DBGF_NOT_ATTACHED);
    1252     AssertReturn(RTSemPongIsSpeaker(&pVM->dbgf.s.PingPong), VERR_SEM_OUT_OF_TURN);
    1253     AssertReturn(idCpu < pVM->cCpus, VERR_INVALID_PARAMETER);
     1256    if (RT_LIKELY(RTSemPongIsSpeaker(&pVM->dbgf.s.PingPong)))
     1257    { /* likely */ }
     1258    else
     1259        return VERR_SEM_OUT_OF_TURN;
    12541260
    12551261    /*
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