Browse Source

pulseaudio: Listen for server events in addition to sources and sinks.

This gets us default device change notifications more efficiently, presumably.
Ryan C. Gordon 1 year ago
parent
commit
62cf24eeb9
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/audio/pulseaudio/SDL_pulseaudio.c

+ 1 - 1
src/audio/pulseaudio/SDL_pulseaudio.c

@@ -865,7 +865,7 @@ static int SDLCALL HotplugThread(void *data)
     SDL_SetThreadPriority(SDL_THREAD_PRIORITY_LOW);
     PULSEAUDIO_pa_threaded_mainloop_lock(pulseaudio_threaded_mainloop);
     PULSEAUDIO_pa_context_set_subscribe_callback(pulseaudio_context, HotplugCallback, NULL);
-    PULSEAUDIO_pa_operation_unref(PULSEAUDIO_pa_context_subscribe(pulseaudio_context, PA_SUBSCRIPTION_MASK_SINK | PA_SUBSCRIPTION_MASK_SOURCE, NULL, NULL));
+    PULSEAUDIO_pa_operation_unref(PULSEAUDIO_pa_context_subscribe(pulseaudio_context, PA_SUBSCRIPTION_MASK_SINK | PA_SUBSCRIPTION_MASK_SOURCE | PA_SUBSCRIPTION_MASK_SERVER, NULL, NULL));
     while (SDL_AtomicGet(&pulseaudio_hotplug_thread_active)) {
         PULSEAUDIO_pa_threaded_mainloop_wait(pulseaudio_threaded_mainloop);