- Timestamp:
- Jul 7, 2021 5:18:31 PM (4 years ago)
- svn:sync-xref-src-repo-rev:
- 145576
- Location:
- trunk/src/VBox/ValidationKit/utils/audio
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/utils/audio/vkat.cpp
r90044 r90079 663 663 int rc = AudioTestSvcCreate(&TstEnv.u.Guest.Srv); 664 664 665 const char *pszDevice = NULL; /* Custom device to use. Can be NULL if not being used. */666 665 const char *pszTag = NULL; /* Custom tag to use. Can be NULL if not being used. */ 667 666 PCPDMDRVREG pDrvReg = AudioTestGetDefaultBackend(); … … 740 739 741 740 case VKAT_TEST_OPT_DEV: 742 pszDevice = ValueUnion.psz; 741 rc = RTStrCopy(TstEnv.szDev, sizeof(TstEnv.szDev), ValueUnion.psz); 742 if (RT_FAILURE(rc)) 743 return RTMsgErrorExitFailure("Failed to copy out device: %Rrc", rc); 743 744 break; 744 745 -
trunk/src/VBox/ValidationKit/utils/audio/vkatCommon.cpp
r89994 r90079 88 88 static int audioTestDevicesEnumerateAndCheck(PAUDIOTESTENV pTstEnv, const char *pszDev, PPDMAUDIOHOSTDEV *ppDev) 89 89 { 90 #ifdef DEBUG_andy 91 return VINF_SUCCESS; 92 #endif 93 94 RTTestSubF(g_hTest, "Enumerating audio devices and checking for device '%s'", pszDev ? pszDev : "<Default>"); 90 RTTestSubF(g_hTest, "Enumerating audio devices and checking for device '%s'", pszDev && *pszDev ? pszDev : "<Default>"); 95 91 96 92 if (!pTstEnv->DrvStack.pIHostAudio->pfnGetDevices) … … 121 117 RTTestPrintf(g_hTest, RTTESTLVL_ALWAYS, "Enum: Output channels = %RU8\n", pDev->cMaxOutputChannels); 122 118 123 if ( pszDev119 if ( (pszDev && *pszDev) 124 120 && !RTStrCmp(pDev->pszName, pszDev)) 125 121 { … … 131 127 RTTestFailed(g_hTest, "Enumerating audio devices failed with %Rrc", rc); 132 128 129 if (RT_SUCCESS(rc)) 130 { 131 if ( (pszDev && *pszDev) 132 && *ppDev == NULL) 133 { 134 RTTestFailed(g_hTest, "Audio device '%s' not found", pszDev); 135 rc = VERR_NOT_FOUND; 136 } 137 } 138 133 139 RTTestSubDone(g_hTest); 134 135 if ( pszDev 136 && *ppDev == NULL) 137 { 138 RTTestFailed(g_hTest, "Audio device '%s' not found", pszDev); 139 return VERR_NOT_FOUND; 140 } 141 142 return VINF_SUCCESS; 140 return rc; 143 141 } 144 142
Note:
See TracChangeset
for help on using the changeset viewer.