[vlc-commits] [Git][videolan/vlc][master] pulse: fix leak on fallback to pipewire

Felix Paul Kühne (@fkuehne) gitlab at videolan.org
Wed Oct 21 16:43:23 UTC 2026



Felix Paul Kühne pushed to branch master at VideoLAN / VLC


Commits:
68e73a7b by Alexandre Janniaux at 2026-10-21T18:30:36+02:00
pulse: fix leak on fallback to pipewire

The pulseaudio operation is released on the normal path but was not
released on the pipewire fallback path.

    Direct leak of 88 byte(s) in 1 object(s) allocated from:
        #0 0x7ffff7921c2b in malloc (/nix/store/ab3753m6i7isgvzphlar0a8xb84gl96i-gcc-15.2.0-lib/lib/libasan.so.8+0x121c2b)
        #1 0x7ffff51eb846 in pa_xmalloc (/nix/store/l9mzvafz6rm2vpb7grxsjn9dskh9nin7-pulseaudio-17.0/lib/libpulse.so.0+0x3f846)
        #2 0x7ffff51d5c79 in pa_operation_new (/nix/store/l9mzvafz6rm2vpb7grxsjn9dskh9nin7-pulseaudio-17.0/lib/libpulse.so.0+0x29c79)
        #3 0x7ffff51c199b in pa_context_send_simple_command (/nix/store/l9mzvafz6rm2vpb7grxsjn9dskh9nin7-pulseaudio-17.0/lib/libpulse.so.0+0x1599b)
        #4 0x7ffff53482ae in Open ../modules/audio_output/pulse.c:1250
        #5 0x7ffff6d58f97 in generic_start ../src/modules/modules.c:261
        #6 0x7ffff6d5ab7a in vlc_module_load ../src/modules/modules.c:230
        #7 0x7ffff6d5aea1 in module_need ../src/modules/modules.c:272
        #8 0x7ffff6f0aed6 in module_need_var ../include/vlc_modules.h:109
        #9 0x7ffff6f0de27 in aout_New ../src/audio_output/output.c:303
        #10 0x7ffff6ed09bf in input_resource_GetAout ../src/input/resource.c:235
        #11 0x7ffff6ec0e21 in vlc_player_aout_Init ../src/player/aout.c:226
        #12 0x7ffff6e9988d in vlc_player_New ../src/player/player.c:2181
        #13 0x7ffff6d825eb in vlc_playlist_PlayerInit ../src/playlist/player.c:144
        #14 0x7ffff6d83254 in vlc_playlist_New ../src/playlist/playlist.c:65
        #15 0x7ffff6d1b082 in libvlc_GetMainPlaylist ../src/libvlc.c:528
        #16 0x7ffff6d73153 in intf_InsertItem ../src/interface/interface.c:154
        #17 0x7ffff6d19696 in GetFilenames ../src/libvlc.c:436
        #18 0x7ffff6d1ad34 in libvlc_InternalInit ../src/libvlc.c:303
        #19 0x7ffff7742903 in libvlc_new ../lib/core.c:68
        #20 0x555555559fb8 in main ../bin/vlc.c:240
        #21 0x7ffff5c2b284 in __libc_start_call_main (/nix/store/jms7zxzm7w1whczwny5m3gkgdjghmi2r-glibc-2.42-51/lib/libc.so.6+0x2b284) (BuildId: 42e795e8858627eb207f0eaa32737fa700483f56)
        #22 0x7ffff5c2b337 in __libc_start_main at GLIBC_2.2.5 (/nix/store/jms7zxzm7w1whczwny5m3gkgdjghmi2r-glibc-2.42-51/lib/libc.so.6+0x2b337) (BuildId: 42e795e8858627eb207f0eaa32737fa700483f56)
        #23 0x555555559404 in _start (/home/janniaux/workspace/vlc/repo/build/bin/vlc-static+0x5404)

    SUMMARY: AddressSanitizer: 88 byte(s) leaked in 1 allocation(s).

- - - - -


1 changed file:

- modules/audio_output/pulse.c


Changes:

=====================================
modules/audio_output/pulse.c
=====================================
@@ -1257,6 +1257,7 @@ static int Open(vlc_object_t *obj)
                 pa_threaded_mainloop_wait(sys->mainloop);
             if (sys->is_pipewire && module_exists("aout_pipewire")) {
                 msg_Dbg(aout, "refusing to use PipeWire");
+                pa_operation_unref(op);
                 pa_threaded_mainloop_unlock(sys->mainloop);
                 vlc_pa_disconnect(obj, sys->context, sys->mainloop);
                 free(sys);



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/68e73a7b9f07f5a95fa77cb4cc4cac554e22f76d

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/68e73a7b9f07f5a95fa77cb4cc4cac554e22f76d
You're receiving this email because of your account on code.videolan.org. Manage all notifications: https://code.videolan.org/-/profile/notifications | Help: https://code.videolan.org/help




More information about the vlc-commits mailing list