VirtualBox

Ignore:
Timestamp:
May 8, 2017 3:04:32 PM (8 years ago)
Author:
vboxsync
Message:

htable.cpp: CrHTablePut should return CRHTABLE_HANDLE_INVALID not VERR_INVALID_PARAMETER. Fixed assertion misconceptions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/GuestHost/OpenGL/util/htable.cpp

    r63369 r66819  
    114114VBOXHTABLEDECL(int) CrHTablePutToSlot(PCRHTABLE pTbl, CRHTABLE_HANDLE hHandle, void* pvData)
    115115{
    116     if (!pvData)
    117     {
    118         AssertMsgFailed(("pvData is NULL\n"));
    119         return VERR_INVALID_PARAMETER;
    120     }
     116    AssertReturn(pvData, VERR_INVALID_PARAMETER);
    121117    uint32_t iIndex = crHTableHandle2Index(hHandle);
    122118    if (iIndex >= pTbl->cSize)
     
    137133VBOXHTABLEDECL(CRHTABLE_HANDLE) CrHTablePut(PCRHTABLE pTbl, void* pvData)
    138134{
    139     if (!pvData)
    140     {
    141         AssertMsgFailed(("pvData is NULL\n"));
    142         return VERR_INVALID_PARAMETER;
    143     }
     135    AssertReturn(pvData, CRHTABLE_HANDLE_INVALID);
    144136
    145137    if (pTbl->cSize == pTbl->cData)
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