Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-02-06avcodec/pngdec: Check trns more completelyMichael Niedermayer
Fixes out of array access Fixes: 546/clusterfuzz-testcase-4809433909559296 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit e477f09d0b3619f3d29173b2cd593e17e2d1978e) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-01-26avcodec/pngdec: Fix off by 1 size in decode_zbuf()Michael Niedermayer
Fixes out of array access Fixes: 444/fuzz-2-ffmpeg_VIDEO_AV_CODEC_ID_PNG_fuzzer Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit e371f031b942d73e02c090170975561fabd5c264) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-18Revert "apngdec: use side data to pass extradata to the decoder"James Almer
This reverts commit e0c6b32046f4bab7d34be77dd2f03b2a80c86d39. Said commit changed the behavior of the demuxer and decoder in a non backwards compatible way. Demuxers should make extradata available at init if possible, and send new extradata as side data within a packet if needed. A better fix for the remuxing crash will follow. Signed-off-by: James Almer <jamrial@gmail.com> (cherry picked from commit 16c429166ddf1736972b6ccce84bd3509ec16a34)
2016-11-18apngdec: use side data to pass extradata to the decoderAndreas Cadhalpun
Fixes remuxing apng streams coming from the apng demuxer. This is a regression since 940b8908b94404a65f9f55e33efb4ccc6c81383c. Found-by: James Almer <jamrial@gmail.com> Reviewed-by: James Almer <jamrial@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> (cherry picked from commit e0c6b32046f4bab7d34be77dd2f03b2a80c86d39) Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-06-21Merge commit '41ed7ab45fc693f7d7fc35664c0233f4c32d69bb'Clément Bœsch
* commit '41ed7ab45fc693f7d7fc35664c0233f4c32d69bb': cosmetics: Fix spelling mistakes Merged-by: Clément Bœsch <u@pkh.me>
2016-05-04cosmetics: Fix spelling mistakesVittorio Giovara
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-04-09avcodec/pngdec: Fix alpha detection with skip_frameMichael Niedermayer
Fixes Ticket4816 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-01-30avcodec/pngdec: use av_mod_uintp2James Almer
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: James Almer <jamrial@gmail.com>
2015-11-16avcodec/pngdec: Replace assert by request for sample for unsupported TRNS casesMichael Niedermayer
Fixes assertion failure Fixes: 7f646252a30ee28b583aac1f82e7985e/signal_sigabrt_7ffff6ae7cc9_7353_62fc077bf2f454d39e188c69807193a6.png Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-11-15lavc/pngdec: set FF_CODEC_CAP_SKIP_FRAME_FILL_PARAM capabilityMatthieu Bouron
2015-11-07apng: use correct size for output bufferAndreas Cadhalpun
The buffer needs s->bpp bytes, at maximum currently 10. Assert that s->bpp is not larger. This fixes a stack buffer overflow. Reviewed-by: wm4 <nfxjfg@googlemail.com> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-02Merge commit '1720791e36f9cc24c05efea5bb275ab52156ce50'Hendrik Leppkes
* commit '1720791e36f9cc24c05efea5bb275ab52156ce50': png: read and write stereo3d frame side data information Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-10-30png: read and write stereo3d frame side data informationKirill Gavrilov
Use optional sTER chunk defining side-by-side stereo pair within "Extensions to the PNG 1.2 Specification", version 1.3.0. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-10-29lavc/pngdec: honor skip_frame optionMatthieu Bouron
2015-10-28avcodec/png: read and write stereo3d frame side data informationKirill Gavrilov
Use optional sTER chunk defining side-by-side stereo pair within "Extensions to the PNG 1.2 Specification", version 1.3.0. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-11avcodec/pngdec: Use av_malloc_array()Michael Niedermayer
Suggested-by: ubitux Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-11avcodec/pngdec: Alloc buffer after blend_op check in handle_p_frame_apng()Michael Niedermayer
Avoids memleak on error Fixes CID1322342 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-11avcodec/pngdec: Check blend_op.Michael Niedermayer
Fixes CID1322359, CID1322358 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-04avcodec: use HAVE_THREADS header guards to silence -Wunused-functionGanesh Ajjanagadde
When compiled with --disable-pthreads, e.g http://fate.ffmpeg.org/report.cgi?time=20150917015044&slot=alpha-debian-qemu-gcc-4.7, a bunch of -Wunused-functions are reported due to missing header guards around threading related functions. This patch should silence such warnings. Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-10-01avcodec/pngdec: mark previous_picture as done on end of decode_frame_common()Michael Niedermayer
Fixes deadlock with threads Found-by: Paul B Mahol Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-09-28avcodec/pngdec: reset has_trns after every decode_frame_png()Paul B Mahol
Fixes #4887. Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-08-31avcodec/pngdec: fully support the tRNS chunkDonny Yang
Signed-off-by: Donny Yang <work@kota.moe>
2015-08-05Merge commit '4fee11ab05fc8569ef35c0ce86a60375c903eefb'Hendrik Leppkes
* commit '4fee11ab05fc8569ef35c0ce86a60375c903eefb': png: Be more informative regarding signature errors Conflicts: libavcodec/pngdec.c Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-02png: Be more informative regarding signature errorsLuca Barbato
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-07-27Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'Michael Niedermayer
* commit 'def97856de6021965db86c25a732d78689bd6bb0': lavc: AV-prefix all codec capabilities Conflicts: cmdutils.c ffmpeg.c ffplay.c libavcodec/8svx.c libavcodec/aacenc.c libavcodec/ac3dec.c libavcodec/adpcm.c libavcodec/alac.c libavcodec/atrac3plusdec.c libavcodec/bink.c libavcodec/dnxhddec.c libavcodec/dvdec.c libavcodec/dvenc.c libavcodec/ffv1dec.c libavcodec/ffv1enc.c libavcodec/fic.c libavcodec/flacdec.c libavcodec/flacenc.c libavcodec/flvdec.c libavcodec/fraps.c libavcodec/frwu.c libavcodec/gifdec.c libavcodec/h261dec.c libavcodec/hevc.c libavcodec/iff.c libavcodec/imc.c libavcodec/libopenjpegdec.c libavcodec/libvo-aacenc.c libavcodec/libvorbisenc.c libavcodec/libvpxdec.c libavcodec/libvpxenc.c libavcodec/libx264.c libavcodec/mjpegbdec.c libavcodec/mjpegdec.c libavcodec/mpegaudiodec_float.c libavcodec/msmpeg4dec.c libavcodec/mxpegdec.c libavcodec/nvenc_h264.c libavcodec/nvenc_hevc.c libavcodec/pngdec.c libavcodec/qpeg.c libavcodec/ra288.c libavcodec/rv10.c libavcodec/s302m.c libavcodec/sp5xdec.c libavcodec/takdec.c libavcodec/tiff.c libavcodec/tta.c libavcodec/utils.c libavcodec/v210dec.c libavcodec/vp6.c libavcodec/vp9.c libavcodec/wavpack.c libavcodec/yop.c Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27lavc: AV-prefix all codec capabilitiesVittorio Giovara
Express bitfields more simply. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-22apng: Fix decoding images with the PREVIOUS dispose opDonny Yang
2015-07-20avcodec/apngdec: Fix typos in decoder causing incorrect resultsDonny Yang
Signed-off-by: Donny Yang <work@kota.moe>
2015-06-29avcodec/pngdec: Check values before updating context in decode_fctl_chunk()Michael Niedermayer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29avcodec/pngdec: Copy IHDR & plte state from last threadMichael Niedermayer
Previously these chunks where parsed again for each frame with threads but not without leading to a different path and the potential for inconsistencies This also removes a related special case from decode_ihdr_chunk() Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29avcodec/pngdec: Require a IHDR chunk before fctlMichael Niedermayer
This is required by the APNG spec Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29avcodec/pngdec: Only allow one IHDR chunkMichael Niedermayer
Multiple IHDR chunks are forbidden in PNG Fixes inconsistency and out of array accesses Fixes: asan_heap-oob_4d5c5a_1738_cov_2638287726_c-m2-8f2b481b7fd9bd745e620b7c01a18df2.png Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-08avcodec/apng: Add partial support for blending with PAL8 pixel formatDonny Yang
Currently restricted to blending pixels that only contain either 0 or 255 in their alpha components Signed-off-by: Donny Yang <work@kota.moe> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-08avcodec/apng: Add support for blending with GRAY8A pixel formatDonny Yang
Signed-off-by: Donny Yang <work@kota.moe> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-08avcodec/apng: Add blending support for non-alpha pixel formatsDonny Yang
Signed-off-by: Donny Yang <work@kota.moe> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-08avcodec/apng: Dispose previous frame properlyDonny Yang
The spec specifies the dispose operation as how the current (i.e., currently being rendered) frame should be disposed when the next frame is blended onto it This is contrary to ffmpeg's current behaviour of interpreting the dispose operation as how the previous (i.e., already rendered) frame should be disposed This patch fixes ffmpeg's behaviour to match those of the spec, which involved a rewrite of the blending function Signed-off-by: Donny Yang <work@kota.moe> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-03avcodec/apng: Remove blending support for AV_PIX_FMT_ARGBDonny Yang
ARGB is not a supported PNG pixel format Signed-off-by: Donny Yang <work@kota.moe> Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-10Merge commit 'b9f7a677083647d85e583d6d7384938766a293d7'Michael Niedermayer
* commit 'b9f7a677083647d85e583d6d7384938766a293d7': png: Set the color range as full range Conflicts: libavcodec/pngdec.c See: 72e7553125e61847d9cab77fb7de62440dca746b Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-09png: Set the color range as full rangewm4
The format uses full range for the gray formats. CC: libav-stable@libav.org
2015-05-08pngdec: set correct rangewm4
AV_PIX_FMT_GRAY8/16 are considered YUV formats, and the color_range is not set - so the API user will have to assume limitted range. (Unless the API user adds a special-case for the PNG decoder.) Just export the correct range - full range. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-03pngdec: don't use AV_PIX_FMT_MONOBLACK for apngAndreas Cadhalpun
AV_PIX_FMT_MONOBLACK has the AV_PIX_FMT_FLAG_BITSTREAM flag, i.e. linesize can be smaller than width. Since x_offset is only check against the width, this can lead to x_offset * bpp >= image_linesize. In this case ptr could be set to a position outside the image_buf in png_handle_row, leading to memory corruption and thus crashes. Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-03pngdec: return correct error code from decode_frame_commonAndreas Cadhalpun
During the loop ret can get changed. Since it is not set on all failure paths, decode_frame_common can return 0 even though an error occurred. Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-03pngdec: check s->last_picture.f->data[0] before using itAndreas Cadhalpun
This check was removed in commit 08aec6f6, but s->last_picture.f->data[0] is still used in handle_p_frame_apng unconditionally. This fixes a segmentation fault. Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-20Merge commit '6a85dfc830f51f1f5c2d36d4182d265c1ea3ba25'Michael Niedermayer
* commit '6a85dfc830f51f1f5c2d36d4182d265c1ea3ba25': lavc: Replace av_dlog and tprintf with internal macros Conflicts: libavcodec/aacdec.c libavcodec/audio_frame_queue.c libavcodec/bitstream.c libavcodec/dcadec.c libavcodec/dnxhddec.c libavcodec/dvbsubdec.c libavcodec/dvdec.c libavcodec/dvdsubdec.c libavcodec/get_bits.h libavcodec/gifdec.c libavcodec/h264.h libavcodec/h264_cabac.c libavcodec/h264_cavlc.c libavcodec/h264_loopfilter.c libavcodec/h264_refs.c libavcodec/imc.c libavcodec/interplayvideo.c libavcodec/jpeglsdec.c libavcodec/libopencore-amr.c libavcodec/mjpegdec.c libavcodec/mpeg12dec.c libavcodec/mpegvideo_enc.c libavcodec/mpegvideo_parser.c libavcodec/pngdec.c libavcodec/ratecontrol.c libavcodec/rv10.c libavcodec/svq1dec.c libavcodec/vqavideo.c libavcodec/wmadec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-19lavc: Replace av_dlog and tprintf with internal macrosVittorio Giovara
2015-01-15Merge commit '1e763454322f7fbc7799f6009bf2e11d7a3b9821'Michael Niedermayer
* commit '1e763454322f7fbc7799f6009bf2e11d7a3b9821': png: improve signature check Conflicts: libavcodec/pngdec.c See: 8a08503b78f59d61cf98b9deb99363e3e07d8599 See: 0a3589bf2f0a23b0eb68664fbb00078abe882a88 Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-14png: improve signature checkVittorio Giovara
Return proper error code, print an error message and add missing parentheses.
2014-12-08avcodec/pngdec: handle 4 more bytes with SIMD for RGB64 in paeth predictionMichael Niedermayer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-08avcodec/x86/pngdsp: fix off by 1 errorMichael Niedermayer
This fixes artifacts in the last pixel of rows with some widths and pixel formats Found-by: Dominique Leroux <Dominique.Leroux@autodesk.com> Tested-by: Dominique Leroux <Dominique.Leroux@autodesk.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-08avcodec/pngdec: check av_image_get_linesize return valueBenoit Fouet
Fixes CID 1257012 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>