Segmentation fault in libtheora.so.0 when using libtheora as vcodec for mpeg4(yuv420p) source

Bug #370382 reported by lirel
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
ffmpeg-debian (Ubuntu)
New
Undecided
Unassigned

Bug Description

while trying to convert a video i could reproduce ffmpeg crashing.

here is the command line:
ffmpeg -i 100_0870.MOV -an -s 960x540 -r 24 -vcodec libtheora -f matroska -y video.mkv
i've been trying the flv codec for vout successfully.

though the file video.mkv gets created it doesn't contain any data afterwards.

$ ls -l .
-rwx------ 1 lirel lirel 1288167 2009-03-14 06:24 100_0870.MOV
-rw-rw---- 1 lirel lirel 0 2009-05-01 16:12 video.mkv

currently i got this entry in my sources.list
deb http://ppa.launchpad.net/afflux/ubuntu intrepid main
this might change he libavcodec version, which i couldn't check.
but still ffmpeg and libtheora comes from ubuntu itsself.

$ dpkg -s libtheora0
Package: libtheora0
Status: install ok installed
Priority: optional
Section: libs
Installed-Size: 664
Maintainer: Ubuntu Core Developers <email address hidden>
Architecture: amd64
Source: libtheora
Version: 1.0~beta3-1
Depends: libc6 (>= 2.4), libogg0 (>= 1.1.0)
Description: The Theora Video Compression Codec ...

some verbose output from ffmpeg from before the crash:

$ ffmpeg -i 100_0870.MOV -an -s 960x540 -r 24 -vcodec libtheora -f matroska -y video.mkv
FFmpeg version r11872+debian_3:0.svn20080206-12ubuntu3.1, Copyright (c) 2000-2008 Fabrice Bellard, et al.
  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 Mar 13 2009 17:52:45, gcc: 4.3.2
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '100_0870.MOV':
  Duration: 00:00:00.8, start: 0.000000, bitrate: 11710 kb/s
    Stream #0.0(eng): Video: mpeg4, yuv420p, 1280x720 [PAR 1:1 DAR 16:9], 30.00 tb(r)
    Stream #0.1(eng): Audio: pcm_mulaw, 16000 Hz, mono, 128 kb/s
Output #0, matroska, to 'video.mkv':
    Stream #0.0(eng): Video: libtheora, yuv420p, 960x540 [PAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 24.00 tb(c)
Stream mapping:
  Stream #0.0 -> #0.0
Press [q] to stop encoding
Segmentation fault

same with gdb running:
$ gdb --args ffmpeg -i 100_0870.MOV -an -s 960x540 -r 24 -vcodec libtheora -f matroska -y video.mkv
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
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-linux-gnu"...
(gdb) run
Starting program: /usr/bin/ffmpeg -i 100_0870.MOV -an -s 960x540 -r 24 -vcodec libtheora -f matroska -y video.mkv
[Thread debugging using libthread_db enabled]
FFmpeg version r11872+debian_3:0.svn20080206-12ubuntu3.1, Copyright (c) 2000-2008 Fabrice Bellard, et al.
  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 Mar 13 2009 17:52:45, gcc: 4.3.2
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '100_0870.MOV':
  Duration: 00:00:00.8, start: 0.000000, bitrate: 11710 kb/s
    Stream #0.0(eng): Video: mpeg4, yuv420p, 1280x720 [PAR 1:1 DAR 16:9], 30.00 tb(r)
    Stream #0.1(eng): Audio: pcm_mulaw, 16000 Hz, mono, 128 kb/s
Output #0, matroska, to 'video.mkv':
    Stream #0.0(eng): Video: libtheora, yuv420p, 960x540 [PAR 1:1 DAR 16:9], q=2-31, 200 kb/s, 24.00 tb(c)
Stream mapping:
  Stream #0.0 -> #0.0
Press [q] to stop encoding
[New Thread 0x7fc7915dc6e0 (LWP 24735)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fc7915dc6e0 (LWP 24735)]
0x00007fc78ebe9600 in ?? () from /usr/lib/libtheora.so.0
(gdb) gdb
Undefined command: "gdb". Try "help".
(gdb) bt
#0 0x00007fc78ebe9600 in ?? () from /usr/lib/libtheora.so.0
#1 0x00007fc78ec011ca in ?? () from /usr/lib/libtheora.so.0
#2 0x00007fc78ebeba09 in ?? () from /usr/lib/libtheora.so.0
#3 0x00007fc78ebf4a3d in theora_encode_YUVin () from /usr/lib/libtheora.so.0
#4 0x00007fc790b6449b in encode_frame (avc_context=0x1ebb500, outbuf=0x7fc78d7a0010 "\024\005v�\016w\n\213Q�\205p���\\+�j?ݰ�\020(PO �L\\�\230u�b\227�N\223",
    buf_size=2073600, data=<value optimized out>) at /build/buildd/ffmpeg-debian-0.svn20080206/libavcodec/libtheoraenc.c:200
#5 0x00007fc7908bd836 in avcodec_encode_video (avctx=0x1ebb500, buf=0x7fc78d7a0010 "\024\005v�\016w\n\213Q�\205p���\\+�j?ݰ�\020(PO �L\\�\230u�b\227�N\223",
    buf_size=2073600, pict=0x7fff99603480) at /build/buildd/ffmpeg-debian-0.svn20080206/libavcodec/utils.c:917
#6 0x0000000000405f9f in output_packet (ist=0x1ecb7b0, ist_index=0, ost_table=0x1ecb850, nb_ostreams=1, pkt=0x7fff99603b70)
    at /build/buildd/ffmpeg-debian-0.svn20080206/ffmpeg.c:837
#7 0x000000000040a762 in av_encode (output_files=0x6139c0, nb_output_files=1, input_files=0x613880, nb_input_files=1, stream_maps=0x613a60, nb_stream_maps=0)
    at /build/buildd/ffmpeg-debian-0.svn20080206/ffmpeg.c:1989
#8 0x000000000040abd6 in main (argc=<value optimized out>, argv=<value optimized out>) at /build/buildd/ffmpeg-debian-0.svn20080206/ffmpeg.c:3939

ProblemType: Bug
Architecture: amd64
DistroRelease: Ubuntu 8.10
Package: ffmpeg 3:0.svn20080206-12ubuntu3.1
ProcEnviron:
 PATH=/ehome/User Name/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
 LANG=de_DE.UTF-8
 SHELL=/bin/bash
SourcePackage: ffmpeg-debian
Uname: Linux 2.6.27-11-generic x86_64

Tags: apport-bug
Revision history for this message
lirel (m8r-lcodw5) wrote :
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.