VirtualBox

Changeset 34418 in vbox for trunk/src/VBox/Runtime


Ignore:
Timestamp:
Nov 26, 2010 5:25:58 PM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
68189
Message:

VBoxExtPAckHelperApp.cpp: More code.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/common/checksum/manifest2.cpp

    r34385 r34418  
    222222
    223223
    224 /**
    225  * Compares two manifests for equality.
    226  *
    227  * @returns true if equals, false if not.
    228  * @param   hManifest1          The first manifest.
    229  * @param   hManifest2          The second manifest.
    230  * @param   papszIgnoreEntries  Entries to ignore.  Ends with a NULL entry.
    231  * @param   papszIgnoreAttrs    Attributes to ignore.  Ends with a NULL entry.
    232  */
    233224RTDECL(int) RTManifestEqualsEx(RTMANIFEST hManifest1, RTMANIFEST hManifest2, const char * const *papszIgnoreEntries,
    234                                const char * const *papszIgnoreAttr)
    235 {
     225                               const char * const *papszIgnoreAttr, char *pszEntry, size_t cbEntry)
     226{
     227    /*
     228     * Validate input.
     229     */
     230    AssertPtrNullReturn(pszEntry, VERR_INVALID_POINTER);
     231    if (pszEntry && cbEntry)
     232        *pszEntry = '\0';
    236233    RTMANIFESTINT *pThis1 = hManifest1;
    237234    RTMANIFESTINT *pThis2 = hManifest1;
    238235    if (pThis1 != NIL_RTMANIFEST)
    239236    {
    240         AssertPtrReturn(pThis1, false);
    241         AssertReturn(pThis1->u32Magic == RTMANIFEST_MAGIC, false);
     237        AssertPtrReturn(pThis1, VERR_INVALID_HANDLE);
     238        AssertReturn(pThis1->u32Magic == RTMANIFEST_MAGIC, VERR_INVALID_HANDLE);
    242239    }
    243240    if (pThis2 != NIL_RTMANIFEST)
    244241    {
    245         AssertPtrReturn(pThis2, false);
    246         AssertReturn(pThis2->u32Magic == RTMANIFEST_MAGIC, false);
     242        AssertPtrReturn(pThis2, VERR_INVALID_HANDLE);
     243        AssertReturn(pThis2->u32Magic == RTMANIFEST_MAGIC, VERR_INVALID_HANDLE);
    247244    }
    248245
     
    251248     */
    252249    if (pThis1 == pThis2)
    253         return true;
     250        return VINF_SUCCESS;
    254251    if (pThis1 == NIL_RTMANIFEST || pThis2 == NIL_RTMANIFEST)
    255         return false;
     252        return VERR_NOT_EQUAL;
    256253
    257254    /*
     
    266263
    267264
    268 /**
    269  * Compares two manifests for equality.
    270  *
    271  * @returns true if equals, false if not.
    272  * @param   hManifest1          The first manifest.
    273  * @param   hManifest2          The second manifest.
    274  */
    275265RTDECL(int) RTManifestEquals(RTMANIFEST hManifest1, RTMANIFEST hManifest2)
    276266{
    277     return RTManifestEqualsEx(hManifest1, hManifest2, NULL /*papszIgnoreEntries*/, NULL /*papszIgnoreAttrs*/);
     267    return RTManifestEqualsEx(hManifest1, hManifest2, NULL /*papszIgnoreEntries*/, NULL /*papszIgnoreAttrs*/, NULL, 0);
    278268}
    279269
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette