VirtualBox

Ignore:
Timestamp:
May 12, 2022 3:22:23 PM (3 years ago)
Author:
vboxsync
Message:

Audio/Mixer: Also need to take the sink's critical section when audioMixerSinkRemoveStreamInternal() is being invoked from AudioMixerDestroy() or AudioMixerSinkDestroy(), without explicitly destroying attached mixer streams before via AudioMixerStreamDestroy() or AudioMixerSinkRemoveAllStreams().

File:
1 edited

Legend:

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

    r94993 r94996  
    672672    pSink->uMagic = AUDMIXSINK_MAGIC_DEAD;
    673673
     674    int rc = RTCritSectEnter(&pSink->CritSect);
     675    AssertRCReturnVoid(rc);
     676
    674677    /*
    675678     * Destroy all streams.
     
    681684        audioMixerStreamDestroyInternal(pStream, pDevIns, true /*fImmediate*/);
    682685    }
     686
     687    rc = RTCritSectLeave(&pSink->CritSect);
     688    AssertRCReturnVoid(rc);
    683689
    684690    /*
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