VirtualBox

Changeset 102678 in vbox for trunk


Ignore:
Timestamp:
Dec 21, 2023 2:08:52 PM (14 months ago)
Author:
vboxsync
Message:

Audio/WAS: Also check the audio interface of an audio device when checking the cache for a race, before adding it to the cache. bugref:10503

File:
1 edited

Legend:

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

    r102638 r102678  
    12911291            {
    12921292                if (   pDevEntry2->cwcDevId == cwcDevId
     1293                    /* Note: We have to compare the device interface here as well, as a cached device entry might
     1294                     * have a stale audio interface for the same device. In such a case a new device entry will be created below. */
     1295                    && pDevEntry2->pIDevice == pIDevice
    12931296                    && pDevEntry2->enmDir   == pCfgReq->enmDir
    12941297                    && RTUtf16Cmp(pDevEntry2->wszDevId, pDevEntry->wszDevId) == 0)
     
    12981301                    pDevEntry = NULL;
    12991302
    1300                     Log8Func(("Lost race adding device '%ls': %p\n", pDevEntry2->wszDevId, pDevEntry2));
     1303                    LogRel2(("WasAPI: Lost race adding device '%ls': %p\n", pDevEntry2->wszDevId, pDevEntry2));
    13011304                    return drvHostAudioWasCacheLookupOrCreateConfig(pThis, pDevEntry2, pCfgReq, fOnWorker, ppDevCfg);
    13021305                }
     
    13041307            RTListPrepend(&pThis->CacheHead, &pDevEntry->ListEntry);
    13051308
    1306             Log8Func(("Added device '%ls' to cache: %p\n", pDevEntry->wszDevId, pDevEntry));
     1309            LogRel2(("WasAPI: Added device '%ls' to cache: %p\n", pDevEntry->wszDevId, pDevEntry));
    13071310            return drvHostAudioWasCacheLookupOrCreateConfig(pThis, pDevEntry, pCfgReq, fOnWorker, ppDevCfg);
    13081311        }
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