VirtualBox

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


Ignore:
Timestamp:
May 4, 2012 2:58:29 PM (13 years ago)
Author:
vboxsync
Message:

fixed tstRTManifest testcase

File:
1 edited

Legend:

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

    r40374 r41170  
    440440    RTMemTmpFree(paFiles);
    441441
     442    RTPrintf("rc = %Rrc\n", rc);
    442443    return rc;
    443444}
     
    454455    switch (enmDigestType)
    455456    {
    456         case RTDIGESTTYPE_CRC32:  pcszDigestType = "CRC32:"; break;
    457         case RTDIGESTTYPE_CRC64:  pcszDigestType = "CRC64:"; break;
    458         case RTDIGESTTYPE_MD5:    pcszDigestType = "MD5:";   break;
    459         case RTDIGESTTYPE_SHA1:   pcszDigestType = "SHA1:";  break;
     457        case RTDIGESTTYPE_CRC32:  pcszDigestType = "CRC32"; break;
     458        case RTDIGESTTYPE_CRC64:  pcszDigestType = "CRC64"; break;
     459        case RTDIGESTTYPE_MD5:    pcszDigestType = "MD5";    break;
     460        case RTDIGESTTYPE_SHA1:   pcszDigestType = "SHA1";   break;
    460461        case RTDIGESTTYPE_SHA256: pcszDigestType = "SHA256"; break;
    461462        default: return VERR_INVALID_PARAMETER;
     
    467468    for (size_t i = 0; i < cFiles; ++i)
    468469    {
    469         size_t cbTmp = strlen(RTPathFilename(paFiles[i].pszTestFile)) + strlen(paFiles[i].pszTestDigest) + 10;
     470        size_t cbTmp = strlen(RTPathFilename(paFiles[i].pszTestFile))
     471                     + strlen(paFiles[i].pszTestDigest)
     472                     + strlen(pcszDigestType)
     473                     + 6;
    470474        cbMaxSize = RT_MAX(cbMaxSize, cbTmp);
    471475        cbSize += cbTmp;
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