Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#59288 - [bs1770gain] Segmentation faults when processing certain audio formats

Attached to Project: Community Packages
Opened by Henrique (hdante) - Tuesday, 10 July 2018, 01:25 GMT
Last edited by Bruno Pagani (ArchangeGabriel) - Sunday, 23 December 2018, 10:41 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Bruno Pagani (ArchangeGabriel)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
When executing bs1170gain on certain audio formats (ex: opus, mp3) it finishes with a segmentation fault. With some audio formats (ex: wav, m4a) the problem doesn't seem to happen, regardless of the audio file.


Additional info:
* package version(s)
bs1770gain 0.4.12-2
ffmpeg 1:4.0.1-2
sox 14.4.2-3

* config and/or log files etc.


Steps to reproduce:
$ bs1770gain audio.opus # Crash
$ bs1770gain audio.m4a # Ok
This task depends upon

Closed by  Bruno Pagani (ArchangeGabriel)
Sunday, 23 December 2018, 10:41 GMT
Reason for closing:  Fixed
Additional comments about closing:  I think it was fixed by 0.5.x release, if not feel free to re-open.
Comment by Doug Newgard (Scimmia) - Sunday, 15 July 2018, 14:53 GMT
Logs? Backtrace? Anything useful?
Comment by Henrique (hdante) - Monday, 16 July 2018, 23:59 GMT
Attaching coredumpctl info bs1770gain. Sample trace follows.

Message: Process 6146 (bs1770gain) of user 1000 dumped core.

Stack trace of thread 6146:
#0 0x00007f7643f9ddb4 __memmove_avx_unaligned_erms (libc.so.6)
#1 0x00007f7644a59fc3 av_packet_copy_props (libavcodec.so.58)
#2 0x00007f7644a5a634 av_packet_ref (libavcodec.so.58)
#3 0x00007f7644ae0cbe avcodec_send_packet (libavcodec.so.58)
#4 0x00007f7644ae1114 n/a (libavcodec.so.58)
#5 0x000055f4148f765b n/a (bs1770gain)
#6 0x000055f4148f7b9c n/a (bs1770gain)
#7 0x000055f4148f95cf n/a (bs1770gain)
#8 0x000055f4148f96b3 n/a (bs1770gain)
#9 0x00007f76442227f3 sox_flow_effects (libsox.so.3)
#10 0x000055f4148f677d n/a (bs1770gain)
#11 0x000055f4148f4628 n/a (bs1770gain)
#12 0x000055f4148f1f43 n/a (bs1770gain)
#13 0x00007f7643e6606b __libc_start_main (libc.so.6)
#14 0x000055f4148f22fa n/a (bs1770gain)
Comment by Henrique (hdante) - Tuesday, 17 July 2018, 00:00 GMT
Core dump
Comment by Henrique (hdante) - Tuesday, 17 July 2018, 00:01 GMT
Core dump doesn't fit max upload size.
Comment by Henrique (hdante) - Tuesday, 17 July 2018, 00:12 GMT
Debug version:

Core was generated by `bs1770gain test.opus'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x0000560a844c8830 in ?? ()
(gdb) bt
#0 0x0000560a844c8830 in ?? ()
#1 0x00007f157a26d70e in av_buffer_unref () from /usr/lib/libavutil.so.56
#2 0x00007f1578d2f033 in av_packet_unref () from /usr/lib/libavcodec.so.58
#3 0x00007f1578db3039 in ?? () from /usr/lib/libavcodec.so.58
#4 0x00007f1578db5d18 in avcodec_send_packet () from /usr/lib/libavcodec.so.58
#5 0x00007f1578db6114 in ?? () from /usr/lib/libavcodec.so.58
#6 0x0000560a834f5753 in frame_reader_run (n=0x560a84448c00) at ffsox_frame_reader.c:172
#7 0x0000560a834f5c80 in ffsox_machine_run (m=m@entry=0x7fff1fbf0de0, node=<optimized out>,
node@entry=0x560a84449fc0) at ffsox_machine.c:30
#8 0x0000560a834f76cf in ffsox_sox_reader_read (sa=sa@entry=0x560a84449fc0, buf=<optimized out>,
len=<optimized out>) at ffsox_sox_reader.c:117
#9 0x0000560a834f77b3 in drain (e=<optimized out>, obuf=<optimized out>, osamp=0x7fff1fbf0ed8)
at ffsox_sox_read_handler.c:56
#10 0x00007f15784f77f3 in sox_flow_effects () from /usr/lib/libsox.so.3
#11 0x0000560a834f462c in ffsox_analyze (ac=ac@entry=0x7fff1fbf11f0, ai=<optimized out>,
vi=<optimized out>) at ffsox_analyze.c:159
#12 0x0000560a834f2698 in bs1770gain_tree_analyze (tree=<optimized out>, odirname=0x0,
options=0x7fff1fbf1300) at bs1770gain_tree.c:141
#13 0x0000560a834eff49 in main (argc=<optimized out>, argv=0x7fff1fbf1528) at bs1770gain.c:970
Comment by Bruno Pagani (ArchangeGabriel) - Wednesday, 18 July 2018, 21:30 GMT
Might be an issue related to ffmpeg 4.0 rebuild. I currently lack time to contact upstream about this (ffmpeg 4.0 compatibility), if you could do it and report that would be great!
Comment by Henrique (hdante) - Wednesday, 18 July 2018, 23:01 GMT
Sure, what's his contact ?
Comment by Bruno Pagani (ArchangeGabriel) - Thursday, 19 July 2018, 08:25 GMT
Peter Belkner <pbelkner@snafu.de>
Comment by Henrique (hdante) - Saturday, 21 July 2018, 17:16 GMT
Hello, I've contacted the upstream developers and have the following information:

1) The crash appears to be in ffsox_analyze.c in a call to sox_flow_effects().
2) The developers see this as an opportunity to make a larger refactor.
3) They want remove SoX code and replace with ffmpeg resampler, while upgrading ffmpeg API usage.
4) The whole refactor with the fix should take some months.

Loading...