VirtualBox

Changeset 89052 in vbox for trunk


Ignore:
Timestamp:
May 14, 2021 7:02:25 PM (4 years ago)
Author:
vboxsync
Message:

Audio/ValKit: More code for VKAT audio test set generation; initial implementation now can pack up tests sets as .tar.gz files [build fix]. bugref:10008

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/AudioTest.cpp

    r89051 r89052  
    731731    AssertPtrReturn(pObj, VERR_NO_MEMORY);
    732732
    733     int rc = RTStrPrintf(pObj->szName, sizeof(pObj->szName), "%04RU32-%s", pSet->cObj, pszName);
    734     AssertRCReturn(rc, rc);
     733    if (RTStrPrintf2(pObj->szName, sizeof(pObj->szName), "%04RU32-%s", pSet->cObj, pszName) <= 0)
     734        AssertFailedReturn(VERR_BUFFER_OVERFLOW);
    735735
    736736    /** @todo Generalize this function more once we have more object types. */
    737737
    738738    char szFilePath[RTPATH_MAX];
    739     rc = RTPathJoin(szFilePath, sizeof(szFilePath), pSet->szPathAbs, pObj->szName);
     739    int rc = RTPathJoin(szFilePath, sizeof(szFilePath), pSet->szPathAbs, pObj->szName);
    740740    AssertRCReturn(rc, rc);
    741741
     
    813813
    814814    char szOutName[RT_ELEMENTS(AUDIOTEST_PATH_PREFIX_STR) + AUDIOTEST_TAG_MAX + 16];
    815     int rc = RTStrPrintf(szOutName, sizeof(szOutName), "%s-%s.tar.gz", AUDIOTEST_PATH_PREFIX_STR, pSet->szTag);
    816     AssertRCReturn(rc, rc);
     815    if (RTStrPrintf2(szOutName, sizeof(szOutName), "%s-%s.tar.gz", AUDIOTEST_PATH_PREFIX_STR, pSet->szTag) <= 0)
     816        AssertFailedReturn(VERR_BUFFER_OVERFLOW);
    817817
    818818    char szOutPath[RTPATH_MAX];
    819     rc = RTPathJoin(szOutPath, sizeof(szOutPath), pszOutDir, szOutName);
     819    int rc = RTPathJoin(szOutPath, sizeof(szOutPath), pszOutDir, szOutName);
    820820    AssertRCReturn(rc, rc);
    821821
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