libavformat doesn't handle containers with > 20 streams
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| FFmpeg |
Incomplete
|
Unknown
|
||
| ffmpeg (Ubuntu) |
Low
|
Unassigned |
Bug Description
Binary package hint: ffmpeg
When I do a
ffmpeg -i /home/jan/The\ Matrix\ -\ HD\ 720p\ x264.mkv
I get a segmentation fault and ffmpeg crashes (the terminal output is attached). The file is about 8.3 gb in size, maybe that's the cause?
I'm using ffmpeg 3:0.svn20080206
Related branches
Jan Rüegg (rggjan) wrote : | #1 |
Jan Rüegg (rggjan) wrote : | #3 |
Ok, I compiled now from SVN with the default options ("./configure" without arguments).
I get:
jan@MacBuntu:
FFmpeg version SVN-r15935, Copyright (c) 2000-2008 Fabrice Bellard, et al.
configuration:
libavutil 49.12. 0 / 49.12. 0
libavcodec 52. 3. 0 / 52. 3. 0
libavformat 52.23. 1 / 52.23. 1
libavdevice 52. 1. 0 / 52. 1. 0
built on Nov 25 2008 17:23:31, gcc: 4.3.2
/media/Synology/The Matrix - HD 720p x264.mkv: memory allocation error occurred
Cutting down the file into a smaller as described on the link makes the recognition work, so I cannot provide a sample file:
jan@MacBuntu:~$ dd if=/media/
10000+0 records in
10000+0 records out
10240000 bytes (10 MB) copied, 4.33087 s, 2.4 MB/s
jan@MacBuntu:~$ file -i /home/jan/
/home/jan/
But that means, it must be the big size of the file, that causes the problem (ffmpeg -i on all the other files in my media library worked).
Now the desired gdb ffmpeg_g output:
jan@MacBuntu:
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-
(gdb) r -i '/media/
Starting program: /home/jan/
FFmpeg version SVN-r15935, Copyright (c) 2000-2008 Fabrice Bellard, et al.
configuration:
libavutil 49.12. 0 / 49.12. 0
libavcodec 52. 3. 0 / 52. 3. 0
libavformat 52.23. 1 / 52.23. 1
libavdevice 52. 1. 0 / 52. 1. 0
built on Nov 25 2008 17:23:31, gcc: 4.3.2
/media/Synology/The Matrix - HD 720p x264.mkv: memory allocation error occurred
Program exited with code 01.
(gdb) bt
No stack.
(gdb) disass $pc-32 $pc+32
No registers.
(gdb) info all-registers
The program has no registers now.
(Didn't seem to work very well though, as the registers are all empty... Maybe a 64-bit problem?)
---
If you need any more information, please tell me!
Changed in ffmpeg: | |
status: | Incomplete → New |
Reinhard Tartler (siretart) wrote : | #4 |
that is pretty surprising. Your initial report contained a segmentation fault, while your last comment indicates an out of memory situation. That is, well, confusing at best, I'd say.
Jan Rüegg (rggjan) wrote : | #5 |
Hmm... is it possible that thesegfault bug was somehow 'fixed' in the SVN, and instead e new bug with this memory allocation error was introduced?
Should I compile the old version directly from SVN to see if it makes some difference with what compile flags for example the ubuntu deb was compiled?
Reinhard Tartler (siretart) wrote : Re: [Bug 301723] Re: ffmpeg -i crashes with segmentation fault | #6 |
Jan Rüegg <email address hidden> writes:
> Hmm... is it possible that thesegfault bug was somehow 'fixed' in the
> SVN, and instead e new bug with this memory allocation error was
> introduced?
That's pretty well possible.
> Should I compile the old version directly from SVN to see if it makes
> some difference with what compile flags for example the ubuntu deb was
> compiled?
That would indeed be interesting. To get the source from the ubuntu
package:
apt-get build-dep ffmpeg-debian
apt-get source ffmpeg-debian
cd ffmpeg-debian*
make -f debian/rules build-stamp-shared
then you should have ffmpeg_g in the subdirectory 'debian-shared' and
can continue with the bug reporting guidelines from the ffmpeg.org
website.
To learn the version and the configure flags used in the ubuntu version
of ffmpeg issue 'ffmpeg --version' on the ubuntu ffmpeg binary.
--
Gruesse/greetings,
Reinhard Tartler, KeyID 945348A4
Trying
apt-get build-dep ffmpeg-debian
apt-get source ffmpeg-debian
cd ffmpeg-debian*
make -f debian/rules build-stamp-shared
I got "make -f debian/rules build-stamp-shared
Building FFmpeg for flavors: static shared
DEB_BUILD_OPTIONS are:
Using as CFLAGS:
make: *** No rule to make target `build-
Instead, I tried:
make -f debian/rules build-stamp
what gave me then much more output when debugging with gdb (see attachement)
'ffmpeg --version' on the ubuntu ffmpeg binary gives me:
FFmpeg version r11872+
configuration: --enable-gpl --enable-pp --enable-swscaler --enable-x11grab --prefix=/usr --enable-libgsm --enable-libtheora --enable-libvorbis --enable-pthreads --disable-strip --enable-libfaad --enable-libfaadbin --enable-liba52 --enable-liba52bin --enable-libdc1394 --enable-shared --disable-static
libavutil version: 49.6.0
libavcodec version: 51.50.0
libavformat version: 52.7.0
libavdevice version: 52.0.0
built on Oct 3 2008 22:41:23, gcc: 4.3.2
ffmpeg: missing argument for option '--version'
Anything else I can do?
Steve Ungerer (public-ungerer) wrote : | #8 |
Encountered a similar issue today that was corrected with information from ffmpeg issue 963: https:/
The input mkv I was working with had > 20 streams; changing MAX_STREAMS to 64 in libavformat/
Reinhard Tartler (siretart) wrote : | #9 |
The problem with changing MAX_STREAMS is that this breaks binary compatibility of libavformat, which means we cannot do this change in ubuntu. This needs solving upstream.
Changed in ffmpeg (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → Low |
summary: |
- ffmpeg -i crashes with segmentation fault + libavformat doesn't handle containers with > 20 streams |
Changed in ffmpeg: | |
status: | Unknown → Confirmed |
Changed in ffmpeg: | |
status: | Confirmed → Incomplete |
Launchpad Janitor (janitor) wrote : | #10 |
This bug was fixed in the package ffmpeg - 4:0.6~svn201005
---------------
ffmpeg (4:0.6~
* merge from debian/
- don't disable encoders
- don't build against libfaad, libdirac and libopenjpeg (all in universe)
ffmpeg (4:0.6~
* update to new upstream. Closes: #569727
- fixes various segfaults and other minor feature improvements
Closes: #374931, #522449, #501891, #559712, #420231, #369127, #538082,
LP: #305286, #457106, #529200, #301723, #305315, #336479, #420230,
#412063, #428912, #432181, #440591, #453732, #453732, #453732,
#514259, #515243, #521472, #530186, #530186, #197842, #483317,
#483317, #539407, #280098, #331255, #566107, #569823, #570305,
#573190
* Fixup lintian overrides for new upstream snapshot
* Bump Standards-Version to 3.8.4
* Many upstream changes, see upstream Changelog for details
-- Reinhard Tartler <email address hidden> Wed, 26 May 2010 00:01:17 +0200
Changed in ffmpeg (Ubuntu): | |
status: | Triaged → Fix Released |
Changed in ffmpeg: | |
status: | Incomplete → Confirmed |
Changed in ffmpeg: | |
status: | Confirmed → Incomplete |
I'm sorry, but the console output is not helpful at all for diagnosing this problem. Please see http:// ffmpeg. org/bugreports. html for guidelines how to submit useful bug reports.
also consider compiling ffmpeg from svn and report your results.