• David Reid's avatar
    PulseAudio: Fix a crash when initializing multiple devices. · d077e92f
    David Reid authored
    This was due to context-level mainloop being accessed from different
    audio threads at the same time. I've fixed this by giving each device
    their own pa_mainloop and pa_context objects.
    
    I considered the idea of having only a single context-level mainloop
    and just using a mutex for mutal exclusion, but that would involve a
    lock in the audio thread's data loop which I wasn't happy about. Also,
    I wasn't sure which thread PulseAudio callbacks would get fired from
    since the main loop would be iterated on different audio threads.
    
    Public issue https://github.com/mackron/miniaudio/issues/376
    d077e92f
miniaudio.h 3.68 MB
The source could not be displayed because it is larger than 1 MB. You can load it anyway or download it instead.