Opened 14 years ago

Last modified 13 years ago

#1794 new defect

segmentation fault in connection with some input jpg files

Reported by: paul@… Owned by: reimar
Priority: normal Component: core
Version: HEAD Severity: normal
Keywords: Cc: paul@…, ubitux
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

when using certain input files (jpg), mencoder crashes.
This happens very rarely, but I can see no fundamental difference between files that work and files that don't.

I first experienced this in 2.1.0rc3 (ubunto lucid), but I just built the latest head revision from svn (r32255), and see the same problem there.

Please find attached some example files for reproduction of the crash.
If i leave away the first file (0.jpg), it works fine.

The commandline i use:

mencoder mf://*.jpg -o test.avi -mf type=jpeg -ovc lavc -lavcopts vcodec=msmpeg4v2:vbitrate=1800:aspect=1 -mf fps=3

Output:
MEncoder SVN-r32255-4.4.3 (C) 2000-2010 MPlayer Team
success: format: 16 data: 0x0 - 0x0
MF file format detected.
[mf] search expr: *.jpg
[mf] number of files: 4 (16)
VIDEO: [IJPG] 0x0 24bpp 3.000 fps 0.0 kbps ( 0.0 kbyte/s)
[V] filefmt:16 fourcc:0x47504A49 size:0x0 fps:3.000 ftime:=0.3333
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1, osd: 1, aspect: 0.000000, round: 1
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffmjpeg] vfm: ffmpeg (FFmpeg MJPEG)
==========================================================================
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
Movie-Aspect is 1.00:1 - prescaling to correct movie aspect.
[swscaler @ 0x89c1380]using unscaled gray -> yuv420p special converter
videocodec: libavcodec (1024x1024 fourcc=3234504d [MP42])
Writing header...
ODML: vprp aspect is 16384:16384.
Writing header...
ODML: vprp aspect is 16384:16384.
Pos: 0.3s 1f (33%) 0.00fps Trem: 0min 0mb A-V:0.000 [0:0]
Movie-Aspect is 1.00:1 - prescaling to correct movie aspect.
[msmpeg4v2 @ 0x891af00]warning, clipping 1 dct coefficients to -127..127
[msmpeg4v2 @ 0x891af00]warning, clipping 1 dct coefficients to -127..127
Segmentation faultf (66%) 0.00fps Trem: 0min 0mb A-V:0.000 [0:0]

Attachments (2)

testdata.tgz (237.1 KB ) - added by paul@… 14 years ago.
testfiles for reproduction of crash
testdata.2.tgz (204.2 KB ) - added by paul@… 14 years ago.
testfiles for reproduction of crash

Download all attachments as: .zip

Change History (7)

by paul@…, 14 years ago

Attachment: testdata.tgz added

testfiles for reproduction of crash

comment:1 by paul@…, 14 years ago

attachments.isobsolete: 01

sorry, wrong attachment, correct one follows...

by paul@…, 14 years ago

Attachment: testdata.2.tgz added

testfiles for reproduction of crash

comment:2 by paul@…, 14 years ago

comment:3 by paul@…, 14 years ago

Cc: paul@… added

comment:4 by compn, 13 years ago

crashes here with svn using mplayer mf://*jpg too
however mplayer mf://0.jpg - 3.jpg individually will not crash.

a gdb bt output would be nice (read bugreports section in docs)

comment:5 by ubitux, 13 years ago

Cc: ubitux@… added

This bug looks like a FFmpeg one:

Program received signal SIGSEGV, Segmentation fault.
0x00000000008bc132 in ff_put_pixels_clamped_mmx (block=0x152e6d0, pixels=0x0, line_size=0) at x86/dsputil_mmx.c:241
241 asm volatile(
(gdb) where
#0 0x00000000008bc132 in ff_put_pixels_clamped_mmx (block=0x152e6d0, pixels=0x0, line_size=0) at x86/dsputil_mmx.c:241
#1 0x00000000007ae090 in mjpeg_decode_scan (s=0x152e100) at mjpegdec.c:823
#2 ff_mjpeg_decode_sos (s=0x152e100) at mjpegdec.c:1002
#3 0x00000000007aec2d in ff_mjpeg_decode_frame (avctx=0x15465d0, data=0x15371f0, data_size=0x7fffffffc4bc, avpkt=<value optimized out>) at mjpegdec.c:1469
#4 0x0000000000875a18 in avcodec_decode_video2 (avctx=0x15465d0, picture=0x15371f0, got_picture_ptr=0x7fffffffc4bc, avpkt=0x7fffffffc440) at utils.c:626
#5 0x00000000005f68a1 in decode (sh=0x14d03c0, data=0x1799c60, len=57164, flags=<value optimized out>) at libmpcodecs/vd_ffmpeg.c:838
#6 0x0000000000506334 in decode_video (sh_video=0x14d03c0, start=0x1799c60 "\377\330\377", <incomplete sequence \340>, in_size=<value optimized out>, drop_frame=0, pts=<value optimized out>, full_frame=0x7fffffffc5bc) at libmpcodecs/dec_video.c:392
#7 0x000000000048debc in update_video (blit_frame=0x7fffffffe698) at mplayer.c:2413
#8 0x0000000000492a20 in main (argc=<value optimized out>, argv=<value optimized out>) at mplayer.c:3765

Note: See TracTickets for help on using tickets.