Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 604352 - media-libs/libass-0.13.5: upgrade causes media-video/mpv to segv
Summary: media-libs/libass-0.13.5: upgrade causes media-video/mpv to segv
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-01-02 08:43 UTC by Michał Górny
Modified: 2017-01-06 08:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-01-02 08:43:12 UTC
After the (supposedly backwards compat?) upgrade of libass to 0.13.5, mpv segfaults when showing OSD text (e.g. changing volume). Additionally, the console is full of:

[osd/libass] [0x7f1098304270]: Warning: no style named 'Default' found

I'll do some rebuilding and testing soonish and get back with more details.
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-01-02 08:55:48 UTC
Ok, rebuilding mpv helps so it looks like an ABI breakage.
Comment 2 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-01-02 09:00:22 UTC
It seems that the only change was increasing length of 'struct ass_style' [1]. However, I don't see mpv using it directly anywhere, so I don't know wtf.

[1]:https://abi-laboratory.pro/tracker/compat_report/libass/0.13.4/0.13.5/5bb5e/abi_compat_report.html#Type_Problems_Low
Comment 3 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-01-02 09:04:58 UTC
Curious enough, after downgrading libass with new mpv rebuild it does not segv but the volume bar does not appear.
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-01-02 09:24:19 UTC
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007f5365c68bb6 in strlen () from /lib64/libc.so.6
[Current thread is 1 (Thread 0x7f535120c700 (LWP 29631))]
(gdb) bt
#0  0x00007f5365c68bb6 in strlen () from /lib64/libc.so.6
#1  0x00007f5365c68886 in strdup () from /lib64/libc.so.6
#2  0x00007f536caa077c in reset_render_context (render_priv=render_priv@entry=0x7f5348371510, style=0x7f5348371778, style@entry=0x0)
    at /usr/src/debug/media-libs/libass-0.13.5/libass-0.13.5/libass/ass_render.c:853
#3  0x00007f536caa08bb in init_render_context (render_priv=render_priv@entry=0x7f5348371510, event=event@entry=0x7f5348676ba0)
    at /usr/src/debug/media-libs/libass-0.13.5/libass-0.13.5/libass/ass_render.c:888
#4  0x00007f536caa0a2d in ass_render_event (render_priv=render_priv@entry=0x7f5348371510, event=event@entry=0x7f5348676ba0, 
    event_images=0x7f534866e448) at /usr/src/debug/media-libs/libass-0.13.5/libass-0.13.5/libass/ass_render.c:2459
#5  0x00007f536caa1504 in ass_render_frame (priv=0x7f5348371510, track=0x7f53486767e0, now=now@entry=0, 
    detect_change=detect_change@entry=0x7f535120bad4) at /usr/src/debug/media-libs/libass-0.13.5/libass-0.13.5/libass/ass_render.c:3015
#6  0x0000000000491e0b in append_ass (ass=ass@entry=0x1d262a8, res=res@entry=0x1d26280, img_list=0x7f5348360e90, changed=changed@entry=0x1d262a0)
    at ../sub/osd_libass.c:526
#7  0x000000000049220b in osd_object_get_bitmaps (osd=osd@entry=0x1d24450, obj=obj@entry=0x1d26230, format=format@entry=1, 
    out_imgs=out_imgs@entry=0x7f535120bbc0) at ../sub/osd_libass.c:541
#8  0x000000000049049f in render_object (osd=osd@entry=0x1d24450, obj=obj@entry=0x1d26230, res=..., video_pts=video_pts@entry=1.335, 
    sub_formats=sub_formats@entry=0x7f535120bc60, out_imgs=out_imgs@entry=0x7f535120bbc0) at ../sub/osd.c:287
#9  0x00000000004909d8 in osd_draw (osd=0x1d24450, res=..., video_pts=1.335, draw_flags=draw_flags@entry=0, formats=formats@entry=0x7f535120bc60, 
    cb=cb@entry=0x4c72da <draw_osd_cb>, cb_ctx=cb_ctx@entry=0x21a6eb0) at ../sub/osd.c:329
#10 0x00000000004c6cc3 in draw_osd (vo=vo@entry=0x21a6eb0) at ../video/out/vo_vdpau.c:686
#11 0x00000000004c6d7a in draw_frame (vo=0x21a6eb0, frame=0x7f5348370330) at ../video/out/vo_vdpau.c:892
#12 0x00000000004c0ad6 in render_frame (vo=vo@entry=0x21a6eb0) at ../video/out/vo.c:814
#13 0x00000000004c0e3b in vo_thread (ptr=0x21a6eb0) at ../video/out/vo.c:914
#14 0x00007f53684013a6 in start_thread () from /lib64/libpthread.so.0
#15 0x00007f5365cd1f0d in clone () from /lib64/libc.so.6
Comment 5 Coacher 2017-01-03 18:15:24 UTC
Yeah, libass is known to add subtle ABI changes between minor releases.
mpv upstream's position on this: 'rebuild mpv, this is not our bug' [1].

mpv ebuild triggers rebuilds on libass' SLOT changes, but 0.13.4 and 0.13.5 have the same SLOT. IMO nothing else can be done with mpv ebuild to prevent problems like this.

Maybe libass ebuild should have SLOT="0/${PV}" ...


[1]: https://github.com/mpv-player/mpv/issues/3985
Comment 6 Alexis Ballier gentoo-dev 2017-01-06 08:42:32 UTC
https://github.com/libass/libass/commit/3b08a1dcb5be8ef42feafdfcbe6a8be97f9a4a9e


"fixed" in 0.13.6