Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#1006121: libvlc5: VLC crash when playing some mpeg2 stream

48 views
Skip to first unread message

Francesco Muzio

unread,
Feb 19, 2022, 9:00:03 AM2/19/22
to
Package: libvlc5
Version: 3.0.16-1
Severity: important
X-Debbugs-Cc: muz...@gmail.com


Dear Maintainer,

VLC crash when playing some mpeg2 stream
Here you can found a downloadable sample recording that crash after 11
seconds: https://www.dropbox.com/s/16qgb3aua8byg6k/Sample-crash_11s.m2t?dl=0

I have experienced this bug with an application that using libvlc to decode
DVB-T streams (Kaffeine), some italian TV broadcasters streams an mpeg2 video
that cause random segmentation fault.

Also VLC crash when playing this streams, but other software like Xine, ffplay
run the entire sample without devastating errors (Xine shows some glitches
after 12 seconds)

-- System Information:
Debian Release: 11.2
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500,
'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 5.10.0-11-amd64 (SMP w/6 CPU threads)
Locale: LANG=it_IT.UTF-8, LC_CTYPE=it_IT.UTF-8 (charmap=UTF-8), LANGUAGE not
set
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages libvlc5 depends on:
ii libc6 2.31-13+deb11u2
ii libvlccore9 3.0.16-1

Versions of packages libvlc5 recommends:
ii libvlc-bin 3.0.16-1

libvlc5 suggests no packages.

Versions of packages libvlc-bin depends on:
ii libc6 2.31-13+deb11u2

Versions of packages vlc depends on:
ii vlc-bin 3.0.16-1
ii vlc-plugin-base 3.0.16-1
ii vlc-plugin-qt 3.0.16-1
ii vlc-plugin-video-output 3.0.16-1

Versions of packages vlc recommends:
ii vlc-l10n 3.0.16-1
ii vlc-plugin-access-extra 3.0.16-1
ii vlc-plugin-notify 3.0.16-1
ii vlc-plugin-samba 3.0.16-1
ii vlc-plugin-skins2 3.0.16-1
ii vlc-plugin-video-splitter 3.0.16-1
ii vlc-plugin-visualization 3.0.16-1

Versions of packages vlc suggests:
pn vlc-plugin-fluidsynth <none>
pn vlc-plugin-jack <none>
pn vlc-plugin-svg <none>

Versions of packages vlc-bin depends on:
ii libc6 2.31-13+deb11u2
ii libvlc-bin 3.0.16-1

Versions of packages vlc-plugin-access-extra depends on:
ii libc6 2.31-13+deb11u2
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libvncclient1 0.9.13+dfsg-2
ii libxcb-composite0 1.14-3
ii libxcb-shm0 1.14-3
ii libxcb1 1.14-3

Versions of packages vlc-plugin-base depends on:
ii liba52-0.7.4 0.7.4-20
ii libarchive13 3.4.3-2+b1
ii libaribb24-0 1.0.3-2
ii libasound2 1.2.4-1.1
ii libass9 1:0.15.0-2
ii libavahi-client3 0.8-5
ii libavahi-common3 0.8-5
ii libavc1394-0 0.5.4-5
ii libavcodec58 7:4.3.3-0+deb11u1
ii libavformat58 7:4.3.3-0+deb11u1
ii libavutil56 7:4.3.3-0+deb11u1
ii libbluray2 1:1.2.1-4+deb11u1
ii libc6 2.31-13+deb11u2
ii libcairo2 1.16.0-5
ii libcddb2 1.3.2-6+b1
ii libchromaprint1 1.5.0-2
ii libdav1d4 0.7.1-3
ii libdbus-1-3 1.12.20-2
ii libdc1394-25 2.2.6-3
ii libdca0 0.0.7-2
ii libdvbpsi10 1.3.3-1
ii libdvdnav4 6.1.0-1+b1
ii libdvdread8 6.1.1-2
ii libebml5 1.4.2-1
ii libfaad2 2.10.0-1
ii libflac8 1.3.3-2
ii libfontconfig1 2.13.1-4.2
ii libfreetype6 2.10.4+dfsg-1
ii libfribidi0 1.0.8-2
ii libgcc-s1 10.2.1-6
ii libgcrypt20 1.8.7-6
ii libglib2.0-0 2.66.8-1
ii libgnutls30 3.7.1-5
ii libgpg-error0 1.38-2
ii libharfbuzz0b 2.7.4-1
ii libixml10 1:1.8.4-2
ii libjpeg62-turbo 1:2.0.6-4
ii libkate1 0.4.1-11
ii liblirc-client0 0.10.1-6.3
ii liblua5.2-0 5.2.4-1.1+b3
ii libmad0 0.15.1b-10
ii libmatroska7 1.6.2-1
ii libmpcdec6 2:0.1~r495-2
ii libmpeg2-4 0.5.1-9
ii libmpg123-0 1.26.4-1
ii libmtp9 1.1.17-3
ii libncursesw6 6.2+20201114-2
ii libnfs13 4.0.0-1
ii libogg0 1.3.4-0.1
ii libopenmpt-modplug1 0.4.11-1
ii libopus0 1.3.1-0.1
ii libpng16-16 1.6.37-3
ii libpostproc55 7:4.3.3-0+deb11u1
ii libprotobuf-lite23 3.12.4-1
ii libpulse0 14.2-2
ii libraw1394-11 2.1.2-2
ii libresid-builder0c2a 2.1.1-15+b1
ii librsvg2-2 2.50.3+dfsg-1
ii libsamplerate0 0.2.1+ds0-1
ii libsdl-image1.2 1.2.12-12
ii libsdl1.2debian 1.2.15+dfsg2-6
ii libsecret-1-0 0.20.4-2
ii libshine3 3.1.1-2
ii libshout3 2.4.5-1+b1
ii libsidplay2 2.1.1-15+b1
ii libsndio7.0 1.5.0-3
ii libsoxr0 0.1.3-4
ii libspatialaudio0 0.3.0+git20180730+dfsg1-2+b1
ii libspeex1 1.2~rc1.2-1.1
ii libspeexdsp1 1.2~rc1.2-1.1
ii libssh2-1 1.9.0-2
ii libstdc++6 10.2.1-6
ii libswscale5 7:4.3.3-0+deb11u1
ii libsystemd0 247.3-6
ii libtag1v5 1.11.1+dfsg.1-3
ii libtheora0 1.1.1+dfsg.1-15
ii libtinfo6 6.2+20201114-2
ii libtwolame0 0.4.0-2
ii libudev1 247.3-6
ii libupnp13 1:1.8.4-2
ii libva-drm2 2.10.0-1
ii libva2 2.10.0-1
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libvorbis0a 1.3.7-1
ii libvorbisenc2 1.3.7-1
ii libx264-160 2:0.160.3011+gitcde9a93-2.1
ii libx265-192 3.4-2
ii libxcb-keysyms1 0.4.0-1+b2
ii libxcb1 1.14-3
ii libxml2 2.9.10+dfsg-6.7
ii libzvbi0 0.2.35-18
ii vlc-data 3.0.16-1
ii zlib1g 1:1.2.11.dfsg-2

Versions of packages vlc-plugin-base recommends:
ii xdg-utils 1.1.3-4.1

Versions of packages vlc-plugin-base suggests:
pn libdvdcss2 <none>

Versions of packages vlc-plugin-notify depends on:
ii libc6 2.31-13+deb11u2
ii libgdk-pixbuf-2.0-0 2.42.2+dfsg-1
ii libglib2.0-0 2.66.8-1
ii libgtk-3-0 3.24.24-4
ii libnotify4 0.7.9-3
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1

Versions of packages vlc-plugin-qt depends on:
ii libc6 2.31-13+deb11u2
ii libgcc-s1 10.2.1-6
ii libqt5core5a 5.15.2+dfsg-9
ii libqt5gui5 5.15.2+dfsg-9
ii libqt5svg5 5.15.2-3
ii libqt5widgets5 5.15.2+dfsg-9
ii libqt5x11extras5 5.15.2-2
ii libstdc++6 10.2.1-6
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libwayland-client0 1.18.0-2~exp1.1
ii libx11-6 2:1.7.2-1

Versions of packages vlc-plugin-qt recommends:
ii vlc-bin 3.0.16-1

Versions of packages vlc-plugin-skins2 depends on:
ii fonts-freefont-ttf 20120503-10
ii libc6 2.31-13+deb11u2
ii libfreetype6 2.10.4+dfsg-1
ii libfribidi0 1.0.8-2
ii libgcc-s1 10.2.1-6
ii libstdc++6 10.2.1-6
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libx11-6 2:1.7.2-1
ii libxext6 2:1.3.3-1.1
ii libxinerama1 2:1.1.4-2
ii libxpm4 1:3.5.12-1
ii vlc-plugin-qt 3.0.16-1

Versions of packages vlc-plugin-skins2 recommends:
ii vlc-bin 3.0.16-1

Versions of packages vlc-plugin-video-output depends on:
ii libaa1 1.4p5-48
ii libavcodec58 7:4.3.3-0+deb11u1
ii libavutil56 7:4.3.3-0+deb11u1
ii libc6 2.31-13+deb11u2
ii libcaca0 0.99.beta19-2.2
ii libegl1 1.3.2-1
ii libgl1 1.3.2-1
ii libgles2 1.3.2-1
ii libplacebo72 2.72.2-1
ii libva-drm2 2.10.0-1
ii libva-wayland2 2.10.0-1
ii libva-x11-2 2.10.0-1
ii libva2 2.10.0-1
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libwayland-client0 1.18.0-2~exp1.1
ii libwayland-egl1 1.18.0-2~exp1.1
ii libx11-6 2:1.7.2-1
ii libxcb-keysyms1 0.4.0-1+b2
ii libxcb-shm0 1.14-3
ii libxcb-xv0 1.14-3
ii libxcb1 1.14-3

Versions of packages vlc-plugin-video-splitter depends on:
ii libc6 2.31-13+deb11u2
ii libvlccore9 [vlc-plugin-abi-3-0-0f] 3.0.16-1
ii libxcb-randr0 1.14-3
ii libxcb1 1.14-3

Versions of packages vlc-plugin-visualization depends on:
ii libc6 2.31-13+deb11u2
ii libgl1 1.3.2-1

Sebastian Ramacher

unread,
Feb 19, 2022, 9:10:04 AM2/19/22
to
Control: tags -1 moreinfo

On 2022-02-19 14:51:05 +0100, Francesco Muzio wrote:
> Package: libvlc5
> Version: 3.0.16-1
> Severity: important
> X-Debbugs-Cc: muz...@gmail.com
>
>
> Dear Maintainer,
>
> VLC crash when playing some mpeg2 stream
> Here you can found a downloadable sample recording that crash after 11
> seconds: https://www.dropbox.com/s/16qgb3aua8byg6k/Sample-crash_11s.m2t?dl=0
>
> I have experienced this bug with an application that using libvlc to decode
> DVB-T streams (Kaffeine), some italian TV broadcasters streams an mpeg2 video
> that cause random segmentation fault.
>
> Also VLC crash when playing this streams, but other software like Xine, ffplay
> run the entire sample without devastating errors (Xine shows some glitches
> after 12 seconds)

I also see glitches, but I cannot reproduce the crash when playing that
file with vlc. Pleae provide a traceback of the crash and the
corresponding logs.

Cheers
--
Sebastian Ramacher
signature.asc

Francesco Muzio

unread,
Feb 19, 2022, 12:40:05 PM2/19/22
to

gdb stack trace of the crash:

Thread 25 "vlc" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffbc7fb700 (LWP 9949)]
0x00007fffab507cb3 in ?? () from /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
(gdb) bt
#0  0x00007fffab507cb3 in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
#1  0x00007fffab4d7f09 in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
#2  0x00007fffab4d6221 in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
#3  0x00007fff7b5a14c5 in  () at /usr/lib/x86_64-linux-gnu/dri/r600_drv_video.so
#4  0x00007fffa0473adf in vaEndPicture () at /usr/lib/x86_64-linux-gnu/libva.so.2
#5  0x00007fff831757c8 in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#6  0x00007fff83185c6e in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#7  0x00007fff82f9dfca in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#8  0x00007fff82f9e70d in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#9  0x00007fff82ca92bb in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#10 0x00007fff82ca9db8 in avcodec_send_packet ()
   at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
#11 0x00007fffbc20966c in  ()
   at /usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libavcodec_plugin.so
#12 0x00007ffff7cb01c8 in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
#13 0x00007ffff7cafdf5 in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
#14 0x00007ffff7cb0412 in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
#15 0x00007ffff7f44ea7 in start_thread (arg=<optimized out>) at pthread_create.c:477
#16 0x00007ffff7e6edef in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95


The crash seems a curious combination between a (probably) not perfect signal reception, libvlc and the driver/hardware video.
It not happens on another machine with same debian release, same architecture and same radeon driver video (but different GPU)
It not happens if I disable HW decoding on VLC

with HW decoding enabled, when VLC start playing, shows me this message:
[00007f91d0c0b170] avcodec decoder: Using Mesa Gallium driver 20.3.5 for AMD RS880 (DRM 2.50.0 / 5.10.0-11-amd64, LLVM 11.0.1) for hardware decoding

when VLC segfaults I see these messages in dmesg logs
[ 9647.012821] vlc[7168]: segfault at 30 ip 00007fe06b0ffcb3 sp 00007fe06846d738 error 4 in r600_dri.so[7fe06a6a5000+d47000]
[ 9647.012857] Code: 1f 84 00 00 00 00 00 48 8b 46 30 ff 60 10 66 0f 1f 84 00 00 00 00 00 48 8b 06 48 8b 40 30 ff 60 18 66 0f 1f 44 00 00 48 8b 06 <48> 8b 40 30 ff 60 20 66 0f 1f 44 00 00 41 57 41 56 41 55 41 54 55

so, as a workaround, I use --avcodec-hw none to VLC (or settings VDPAU_DRIVER=none LIBVA_DRIVER_NAME=none for other software using libvlc) to avoid the crash


Sebastian Ramacher

unread,
Feb 19, 2022, 1:40:03 PM2/19/22
to
Control: reassign -1 mesa-va-drivers 20.3.5-1

On 2022-02-19 18:38:32 +0100, Francesco Muzio wrote:
> gdb stack trace of the crash:
>
> Thread 25 "vlc" received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 0x7fffbc7fb700 (LWP 9949)]
> 0x00007fffab507cb3in ??() from /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
> (gdb) bt
> #0 0x00007fffab507cb3in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
> #1 0x00007fffab4d7f09in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
> #2 0x00007fffab4d6221in  () at /usr/lib/x86_64-linux-gnu/dri/r600_dri.so
> #3 0x00007fff7b5a14c5in  () at
> /usr/lib/x86_64-linux-gnu/dri/r600_drv_video.so
> #4 0x00007fffa0473adfin vaEndPicture() at
> /usr/lib/x86_64-linux-gnu/libva.so.2
> #5 0x00007fff831757c8in  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #6 0x00007fff83185c6ein  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #7 0x00007fff82f9dfcain  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #8 0x00007fff82f9e70din  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #9 0x00007fff82ca92bbin  () at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #10 0x00007fff82ca9db8in avcodec_send_packet()
>    at /usr/lib/x86_64-linux-gnu/libavcodec.so.58
> #11 0x00007fffbc20966cin  ()
>    at /usr/lib/x86_64-linux-gnu/vlc/plugins/codec/libavcodec_plugin.so
> #12 0x00007ffff7cb01c8in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
> #13 0x00007ffff7cafdf5in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
> #14 0x00007ffff7cb0412in  () at /usr/lib/x86_64-linux-gnu/libvlccore.so.9
> #15 0x00007ffff7f44ea7in start_thread(arg=<optimized out>) at
> pthread_create.c:477
> #16 0x00007ffff7e6edefin clone() at
> ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
>
>
> The crash seems a curious combination between a (probably) not perfect
> signal reception, libvlc and the driver/hardware video.
> It not happens on another machine with same debian release, same
> architecture and same radeon driver video (but different GPU)
> It not happens if I disable HW decoding on VLC
>
> with HW decoding enabled, when VLC start playing, shows me this message:
> [00007f91d0c0b170] avcodec decoder: Using Mesa Gallium driver 20.3.5 for AMD
> RS880 (DRM 2.50.0 / 5.10.0-11-amd64, LLVM 11.0.1) for hardware decoding

So this sounds a lot like a bug in the vaapi driver for that GPU.
Especially since playing without hardware decoding works as expected.
Reassigning accordingly.

Cheers

>
> when VLC segfaults I see these messages in dmesg logs
> [ 9647.012821] vlc[7168]: segfault at 30 ip 00007fe06b0ffcb3 sp
> 00007fe06846d738 error 4 in r600_dri.so[7fe06a6a5000+d47000]
> [ 9647.012857] Code: 1f 84 00 00 00 00 00 48 8b 46 30 ff 60 10 66 0f 1f 84
> 00 00 00 00 00 48 8b 06 48 8b 40 30 ff 60 18 66 0f 1f 44 00 00 48 8b 06 <48>
> 8b 40 30 ff 60 20 66 0f 1f 44 00 00 41 57 41 56 41 55 41 54 55
>
> so, as a workaround, I use --avcodec-hw none to VLC (or settings
> VDPAU_DRIVER=none LIBVA_DRIVER_NAME=none for other software using libvlc) to
> avoid the crash
>

--
Sebastian Ramacher
signature.asc

Francesco Muzio

unread,
Feb 19, 2022, 2:40:03 PM2/19/22
to
I do not agree, because Xine using hardware acceleration (if I don't
force to disable it by setting LIBVA_DRIVER_NAME,VDPAU_DRIVER ) and
playing entire sample only with a glitch.
VLC must do it with the same behaviour
0 new messages