VirtualBox

Changeset 65999 in vbox


Ignore:
Timestamp:
Mar 8, 2017 8:04:19 PM (8 years ago)
Author:
vboxsync
Message:

AssertReturn on each condition is much more helpful when debugging.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostServices/SharedFolders/vbsf.cpp

    r65288 r65999  
    14121412
    14131413
    1414     if (   !(type == SHFL_HF_TYPE_DIR || type == SHFL_HF_TYPE_FILE)
    1415         || pcbBuffer == 0
    1416         || pObjInfo == 0
    1417         || *pcbBuffer < sizeof(SHFLFSOBJINFO))
    1418     {
    1419         AssertFailed();
    1420         return VERR_INVALID_PARAMETER;
    1421     }
     1414    AssertReturn(type == SHFL_HF_TYPE_DIR || type == SHFL_HF_TYPE_FILE, VERR_INVALID_PARAMETER);
     1415    AssertReturn(pcbBuffer != NULL, VERR_INVALID_PARAMETER);
     1416    AssertReturn(pObjInfo != NULL, VERR_INVALID_PARAMETER);
     1417    AssertReturn(*pcbBuffer >= sizeof(SHFLFSOBJINFO), VERR_INVALID_PARAMETER);
    14221418
    14231419    /** @todo other options */
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