#351 closed defect (fixed)
mencoder segfaults on duplicate frames with -vf harddup
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | normal | Component: | vf |
Version: | HEAD | Severity: | normal |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Reproduced by developer: | no | Analyzed by developer: | no |
Description
Note: This is my first bug report filed here, I believe it is correct according
to your guidelines, pls advise if it is not.
I have a large raw file from TV snap card (raw audio + video). After splitting
into multiple chunks (mencoder crashed on big file), mencoder crashes on only
certain input files.
This command fails:
mencoder /mnt/mroot/hdd2/ea-0014.avi -of mpeg -vf harddup -oac lavc -ovc lavc
-lavcopts
acodec=ac3:abitrate=192:vcodec=mpeg2video:keyint=25:vqmin=1:vqmax=9:vbitrate=7000:aspect=4/3
-srate 48000 -ofps 30000/1001 -o gbr.mpg
Re-encoding with just -ovc lavc works.
mencoder -ovc lavc -oac pcm -o rc.avi /mnt/mroot/hdd2/ea-0014.avi
Then, I noticed the original command segfaults at the same spot where the
shortened command starts to complain about A duplicate frame.
Then, upon realizing this, I removed the -vf harddup (unsure why Im using it
anyways), and it works fine.
Following the directions on this site, here is the gdb info I believe is
requested for a bug report.
(gdb) run /mnt/mroot/hdd2/ea-0014.avi -of mpeg -vf harddup -oac lavc -ovc lavc
-lavcopts
acodec=ac3:abitrate=192:vcodec=mpeg2video:keyint=25:vqmin=1:vqmax=9:vbitrate=7000:aspect=4/3
-srate 48000 -ofps 30000/1001 -o gbr.mpg
Starting program: /usr/local/bin/mencoder /mnt/mroot/hdd2/ea-0014.avi -of mpeg
-vf harddup -oac lavc -ovc lavc -lavcopts
acodec=ac3:abitrate=192:vcodec=mpeg2video:keyint=25:vqmin=1:vqmax=9:vbitrate=7000:aspect=4/3
-srate 48000 -ofps 30000/1001 -o gbr.mpg
[Thread debugging using libthread_db enabled]
[New Thread 16384 (LWP 32591)]
Using GNU internationalization
Original domain: messages
Original dirname: /usr/share/locale
Current domain: mplayer
Current dirname: /usr/local/share/locale
MEncoder dev-CVS-050731-14:17-3.3.5-20050130 (C) 2000-2005 MPlayer Team
CPU: Advanced Micro Devices Athlon MP/XP Thoroughbred (Family: 6, Stepping: 0)
Detected cache-line size is 64 bytes
3DNowExt supported but disabled
CPUflags: Type: 6 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 0 SSE: 1 SSE2: 0
Compiled for x86 CPU with extensions: MMX MMX2 3DNow SSE
File not found: 'frameno.avi'
Failed to open frameno.avi
success: format: 0 data: 0x0 - 0x80073730
AVI file format detected.
Detected NON-INTERLEAVED AVI file format.
VIDEO: [YV12] 720x480 24bpp 29.970 fps 120463.6 kbps (14705.0 kbyte/s)
[V] filefmt:3 fourcc:0x32315659 size:720x480 fps:29.97 ftime:=0.0334
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 48000 Hz, 2 ch, s16le, 1536.0 kbit/100.00% (ratio: 192000->192000)
Selected audio codec: [pcm] afm:pcm (Uncompressed PCM)
==========================================================================
PACKET SIZE: 2048 bytes
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1, osd: 1, aspect: 0.000000, round: 1
Opening video filter: [harddup]
==========================================================================
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 720 x 480 (preferred csp: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is undefined - no prescaling applied.
videocodec: libavcodec (720x480 fourcc=3267706d [mpg2])
Selected video codec: [rawyv12] vfm:raw (RAW YV12)
==========================================================================
Building audio filter chain for 48000Hz/2ch/s16le -> 48000Hz/0ch/??...
Building audio filter chain for 48000Hz/2ch/s16le -> 48000Hz/2ch/s16le...
Writing AVI header...
Limiting audio preload to 0.4s
Increasing audio density to 4
New_Face failed. Maybe the font path is wrong.
Please supply the text font file (~/.mplayer/subfont.ttf).
subtitle font: load_sub_face failed.
INITIAL DELAY of 0 frames 20fps Trem: 3min 0mb A-V:0.031 [0:192]
Pos: 22.3s 669f (16%) 24fps Trem: 2min 119mb A-V:0.033 [7077:192]
1 duplicate frame(s)!
Pos: 22.4s 671f (16%) 24fps Trem: 2min 119mb A-V:0.033 [7078:192]
1 duplicate frame(s)!
Pos: 22.4s 673f (16%) 24fps Trem: 2min 118mb A-V:0.033 [7076:192]
1 duplicate frame(s)!
Pos: 22.5s 675f (16%) 24fps Trem: 2min 118mb A-V:0.033 [7075:192]
1 duplicate frame(s)!
Pos: 22.6s 677f (16%) 24fps Trem: 2min 118mb A-V:0.033 [7076:192]
1 duplicate frame(s)!
Pos: 22.6s 679f (16%) 24fps Trem: 2min 116mb A-V:0.033 [7076:192]
1 duplicate frame(s)!
Pos: 22.7s 681f (16%) 24fps Trem: 2min 118mb A-V:0.033 [7075:192]
1 duplicate frame(s)!
Pos: 22.8s 683f (16%) 24fps Trem: 2min 118mb A-V:0.033 [7080:192]
1 duplicate frame(s)!
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 32591)]
0xb7a6562c in memcpy () from /lib/libc.so.6
(gdb) bt
#0 0xb7a6562c in memcpy () from /lib/libc.so.6
#1 0x080b7958 in memcpy_pic (dst=0xb77a4008, src=0xb7421040, bytesPerLine=720,
height=-1220407232, dstStride=720, srcStride=345600) at fastmemcpy.h:64
#2 0x080b76f4 in put_image (vf=0x85d5c50, mpi=0x863f118) at vf_expand.c:352
#3 0x080ac369 in vf_next_put_image (vf=0xb77a4008, mpi=0xb77a4008) at vf.c:625
#4 0x080be65a in control (vf=0x85d5ce8, request=11, data=0x0) at vf_harddup.c:49
#5 0x0806d667 in main (argc=-1216724984, argv=0xb77a4008) at mencoder.c:1331
(gdb) disass $pc-32 $pc+32
Dump of assembler code from 0xb7a6560c to 0xb7a6564c:
0xb7a6560c <memcpy_chk+12>: push %es
0xb7a6560d <memcpy_chk+13>: add %cl,0x244c8bf6(%ecx)
0xb7a65613 <memcpy+3>: or $0x89,%al
0xb7a65615 <memcpy+5>: clc
0xb7a65616 <memcpy+6>: mov 0x4(%esp),%edi
0xb7a6561a <memcpy+10>: mov %esi,%edx
0xb7a6561c <memcpy+12>: mov 0x8(%esp),%esi
0xb7a65620 <memcpy+16>: cld
0xb7a65621 <memcpy+17>: shr %ecx
0xb7a65623 <memcpy+19>: jae 0xb7a65626 <memcpy+22>
0xb7a65625 <memcpy+21>: movsb %ds:(%esi),%es:(%edi)
0xb7a65626 <memcpy+22>: shr %ecx
0xb7a65628 <memcpy+24>: jae 0xb7a6562c <memcpy+28>
0xb7a6562a <memcpy+26>: movsw %ds:(%esi),%es:(%edi)
0xb7a6562c <memcpy+28>: repz movsl %ds:(%esi),%es:(%edi)
0xb7a6562e <memcpy+30>: mov %eax,%edi
0xb7a65630 <memcpy+32>: mov %edx,%esi
0xb7a65632 <memcpy+34>: mov 0x4(%esp),%eax
0xb7a65636 <memcpy+38>: ret
0xb7a65637 <memcpy+39>: nop
0xb7a65638 <memcpy+40>: nop
0xb7a65639 <memcpy+41>: nop
0xb7a6563a <memcpy+42>: nop
0xb7a6563b <memcpy+43>: nop
---Type <return> to continue, or q <return> to quit---info all-registers
0xb7a6563c <memcpy+44>: nop
0xb7a6563d <memcpy+45>: nop
0xb7a6563e <memcpy+46>: nop
0xb7a6563f <memcpy+47>: nop
0xb7a65640 <memcpy+48>: sub $0x10,%esp
0xb7a65643 <memcpy+51>: mov %edi,0x8(%esp)
0xb7a65647 <memcpy+55>: mov %ebx,(%esp)
0xb7a6564a <memcpy+58>: mov %esi,0x4(%esp)
End of assembler dump.
(gdb) info all-registers
eax 0xb77a4008 -1216724984
ecx 0x15180 86400
edx 0xb7421040 -1220407232
ebx 0x863f188 140767624
esp 0xbfea82ac 0xbfea82ac
ebp 0xbfea82d8 0xbfea82d8
esi 0xb77a4008 -1216724984
edi 0xb7421040 -1220407232
eip 0xb7a6562c 0xb7a6562c
eflags 0x210212 2163218
cs 0x73 115
ss 0x7b 123
ds 0x7b 123
es 0x7b 123
fs 0x0 0
gs 0x33 51
st0 -nan(0x80807e7f7c7f7b7c) (raw 0xffff80807e7f7c7f7b7c)
st1 -nan(0x800080007e007f) (raw 0xffff00800080007e007f)
st2 -0.066733333333333333332914108493305605 (raw 0xbffb88ab7c61c2038cc4)
st3 0.033365750701168747638369893593335291 (raw 0x3ffa88aa868116907000)
st4 0.033365750701168747638369893593335291 (raw 0x3ffa88aa868116907000)
st5 2002 (raw 0x4009fa40000000000000)
st6 -2.1959853172259820980848077365266136e-05 (raw
0xbfefb8366cf41d99e000)
st7 -0.033388626519838926487437902324018069 (raw 0xbffa88c2832f60874000)
---Type <return> to continue, or q <return> to quit---
fctrl 0x37f 895
fstat 0x420 1056
ftag 0xffff 65535
fiseg 0x0 0
fioff 0x0 0
foseg 0x0 0
fooff 0x0 0
fop 0x0 0
xmm0 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm1 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm2 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm3 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm4 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
---Type <return> to continue, or q <return> to quit---
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm5 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm6 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
xmm7 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0}, v4_int32 = {0x0, 0x0, 0x0, 0x0}, v2_int64 = {0x0, 0x0},
uint128 = 0x00000000000000000000000000000000}
mxcsr 0x1f80 8064
mm0 {uint64 = 0x80807e7f7c7f7b7c, v2_int32 = {0x7c7f7b7c, 0x80807e7f},
v4_int16 = {0x7b7c, 0x7c7f, 0x7e7f, 0x8080}, v8_int8 = {0x7c, 0x7b, 0x7f, 0x7c,
0x7f, 0x7e, 0x80, 0x80}}
mm1 {uint64 = 0x800080007e007f, v2_int32 = {0x7e007f, 0x800080},
v4_int16 = {0x7f, 0x7e, 0x80, 0x80}, v8_int8 = {0x7f, 0x0, 0x7e, 0x0, 0x80, 0x0,
0x80, 0x0}}
mm2 {uint64 = 0x88ab7c61c2038cc4, v2_int32 = {0xc2038cc4, 0x88ab7c61},
v4_int16 = {0x8cc4, 0xc203, 0x7c61, 0x88ab}, v8_int8 = {0xc4, 0x8c, 0x3, 0xc2,
0x61, 0x7c, 0xab, 0x88}}
---Type <return> to continue, or q <return> to quit---
mm3 {uint64 = 0x88aa868116907000, v2_int32 = {0x16907000, 0x88aa8681},
v4_int16 = {0x7000, 0x1690, 0x8681, 0x88aa}, v8_int8 = {0x0, 0x70, 0x90, 0x16,
0x81, 0x86, 0xaa, 0x88}}
mm4 {uint64 = 0x88aa868116907000, v2_int32 = {0x16907000, 0x88aa8681},
v4_int16 = {0x7000, 0x1690, 0x8681, 0x88aa}, v8_int8 = {0x0, 0x70, 0x90, 0x16,
0x81, 0x86, 0xaa, 0x88}}
mm5 {uint64 = 0xfa40000000000000, v2_int32 = {0x0, 0xfa400000},
v4_int16 = {0x0, 0x0, 0x0, 0xfa40}, v8_int8 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x40, 0xfa}}
mm6 {uint64 = 0xb8366cf41d99e000, v2_int32 = {0x1d99e000, 0xb8366cf4},
v4_int16 = {0xe000, 0x1d99, 0x6cf4, 0xb836}, v8_int8 = {0x0, 0xe0, 0x99, 0x1d,
0xf4, 0x6c, 0x36, 0xb8}}
mm7 {uint64 = 0x88c2832f60874000, v2_int32 = {0x60874000, 0x88c2832f},
v4_int16 = {0x4000, 0x6087, 0x832f, 0x88c2}, v8_int8 = {0x0, 0x40, 0x87, 0x60,
0x2f, 0x83, 0xc2, 0x88}}
(gdb)