VirtualBox

Changeset 76670 in vbox for trunk


Ignore:
Timestamp:
Jan 7, 2019 11:01:21 AM (6 years ago)
Author:
vboxsync
Message:

Audio/PulseAudio: Bail out early in device enumeration when we're unable to get the PulseAudio server information for whatever reason.

File:
1 edited

Legend:

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

    r76553 r76670  
    11431143
    11441144    pThis->fEnumOpSuccess = false;
    1145     int rc = paWaitFor(pThis, pa_context_get_server_info(pThis->pContext, paEnumServerCb, &CbCtx));
     1145
     1146    LogRel(("PulseAudio: Retrieving server information ...\n"));
     1147
     1148    /* Check if server information is available and bail out early if it isn't. */
     1149    pa_operation *paOpServerInfo = pa_context_get_server_info(pThis->pContext, paEnumServerCb, &CbCtx);
     1150    if (!paOpServerInfo)
     1151    {
     1152        pa_threaded_mainloop_unlock(pThis->pMainLoop);
     1153
     1154        LogRel(("PulseAudio: Server information not available, skipping enumeration\n"));
     1155        return VINF_SUCCESS;
     1156    }
     1157
     1158    int rc = paWaitFor(pThis, paOpServerInfo);
    11461159    if (RT_SUCCESS(rc) && !pThis->fEnumOpSuccess)
    11471160        rc = VERR_AUDIO_BACKEND_INIT_FAILED; /* error code does not matter */
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