aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* swscale/swscale_unscaled: Fix odd height inputs for bayer_to_yv12_wrapper()Michael Niedermayer2016-01-171-1/+6
| | | | | | | | Fixes: 372d2df1f04b49e25f109f07f90b1505/asan_heap-oob_2835d2e_8501_99e0114d7ba3a6db885d0b4684d200c1.cine Fixes out of array read Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/swscale_unscaled: Fix odd height inputs for bayer_to_rgb24_wrapper()Michael Niedermayer2016-01-171-1/+6
| | | | | | | | Fixes: 372d2df1f04b49e25f109f07f90b1505/asan_heap-oob_2835d2e_8501_99e0114d7ba3a6db885d0b4684d200c1.cine Fixes out of array read Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* ffmpeg: fix sws_dict leak on error exitMichael Niedermayer2016-01-171-0/+2
| | | | | | | Fixes: 1b79b985cdf860ffa228c00ee5497051/signal_sigsegv_1f99d24_3549_86d92054a79f6ff900fbaf03f8012b32.aif Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* x86/fixed_dsp: add ff_butterflies_fixed_sse2James Almer2016-01-165-0/+90
| | | | | Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/wmaenc: Check input for finitenessMichael Niedermayer2016-01-161-2/+11
| | | | | | | | Fixes out of array read Fixes: 1b79b985cdf860ffa228c00ee5497051/signal_sigsegv_1f99d24_315_f0f1fdb451264b1138e9c24eb7d49181.wv Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/aacenc: Check both channels for finitenessMichael Niedermayer2016-01-161-8/+8
| | | | | | | | Fixes null pointer dereference Fixes: 10412fc52ecc6eab40ed67f82ca7b372/signal_sigsegv_2618c99_2129_f808373959e46afb165593332799ffbc.aif Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavf/matroskadec: Get sample size from private dataMats Peterson2016-01-161-2/+8
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavf/mov: Don't limit fourcc 0 -> raw/twos to version 0 sample descriptionsMats Peterson2016-01-161-1/+1
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/motion_est: Attempt to fix "short data segment overflowed" on IA64Michael Niedermayer2016-01-161-0/+4
| | | | | | | This decreases the MV related encoding table sizes This should have little effect on real world video encoding performance Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* mpeg4videodec: silence ubsan warningAndreas Cadhalpun2016-01-151-1/+1
| | | | | | | | | | | | | | | s->ac_val[0][0] is of type 'int16_t [16]', but points into a larger buffer. Here it is used as base pointer to find the correct position in the larger buffer by adding 's->block_index[n] * 16' and thus as 'int16_t *'. This fixes clang's ubsan runtime error: index out of bounds for type 'int16_t [16]' Fixes: test_case.mp4 Found-by: Tyson Smith <twsmith@mozilla.com> Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* lavu/x86/lls: add fma3 optimizations for update_llsGanesh Ajjanagadde2016-01-152-2/+61
| | | | | | | | | | | | | | | | | | | | | This improves accuracy (very slightly) and speed for processors having fma3. Sample benchmark (fate flac-16-lpc-cholesky, Haswell): old: 5993610 decicycles in ff_lpc_calc_coefs, 64 runs, 0 skips 5951528 decicycles in ff_lpc_calc_coefs, 128 runs, 0 skips new: 5252410 decicycles in ff_lpc_calc_coefs, 64 runs, 0 skips 5232869 decicycles in ff_lpc_calc_coefs, 128 runs, 0 skips Tested with FATE and --disable-fma3, also examined contents of lavu/lls-test. Reviewed-by: James Almer <jamrial@gmail.com> Reviewed-by: Henrik Gramner <henrik@gramner.com> Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
* avfilter/af_sidechaincompress & af_agate: use audio fifo from lavuPaul B Mahol2016-01-152-55/+102
| | | | | | Fixes regression causing segfault. Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avformat/riff: add C210 FourCC (Canopus C210)Piotr Bandurski2016-01-151-0/+1
|
* avformat/riff: add YUYV FourCC (Drastic YUYV)Piotr Bandurski2016-01-152-0/+2
|
* avfilter: add ahistogram multimedia filterPaul B Mahol2016-01-156-1/+493
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* x86/intmath: add missing early clobber to output operandsJames Almer2016-01-151-2/+2
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec/x86/fmtconvert: Add emms to int32_to_float_fmul_array8_sse()Michael Niedermayer2016-01-151-1/+8
| | | | | | this should fix checkasm on x86_64-archlinux-gcc-valgrind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avfilter/vaf_spectrumsynth: Fix mixed declaration and statmentMichael Niedermayer2016-01-151-1/+2
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/hls: Even stricter URL checksMichael Niedermayer2016-01-151-1/+5
| | | | | | This fixes a null pointer dereference at least Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/hls: More strict url checksMichael Niedermayer2016-01-151-0/+4
| | | | | | No case is known where these are needed Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/rmdec: add missing av_log argumentJames Almer2016-01-151-1/+1
| | | | | | Also change the format specifier to expect an unsigned int Signed-off-by: James Almer <jamrial@gmail.com>
* lavf/mov: Confine 0x00000000 to raw/twos fourcc mapping to version 0 sample ↵Mats Peterson2016-01-151-1/+1
| | | | | | | | | | descriptions Confine the 0x00000000 to 'raw '/'twos' fourcc mapping to old version 0 sound sample descriptions, since they are the only valid sample descriptions for this type of mapping. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/pngenc: Fix mixed up linesizesMichael Niedermayer2016-01-151-2/+2
| | | | | | | | Fixes out of array accesses Fixes: 0cf176e6d3ab9fe924f39738e513f547/asan_generic_4a54aa_3431_aaa28be1cb32e307a9890cad06f84fba.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec/pngenc: Replace memcpy by av_image_copy()Michael Niedermayer2016-01-151-6/+3
| | | | | | | | Fixes out of array access Fixes: 0cf176e6d3ab9fe924f39738e513f547/asan_generic_4a54aa_3431_aaa28be1cb32e307a9890cad06f84fba.avi Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* asfdec_o: check for too small size in asf_read_unknownAndreas Cadhalpun2016-01-151-1/+6
| | | | | | | This fixes infinite loops due to seeking back. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: break if EOF is reached after asf_read_packet_headerAndreas Cadhalpun2016-01-151-0/+2
| | | | | | | | | | asf_read_payload can unset eof_reached, so check it also before calling that function. This fixes infinite loops. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: make sure packet_size is non-zero before seekingAndreas Cadhalpun2016-01-151-0/+4
| | | | | | | This fixes infinite loops due to seeking back. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: prevent overflow causing seekbackAndreas Cadhalpun2016-01-151-1/+1
| | | | | | | This fixes infinite loops. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: check avio_skip in asf_read_simple_indexAndreas Cadhalpun2016-01-151-2/+6
| | | | | | | The loop can be very long, even though the file is very short. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: reject size > INT64_MAX in asf_read_unknownAndreas Cadhalpun2016-01-151-0/+3
| | | | | | | | | | Both avio_skip and detect_unknown_subobject use int64_t for the size parameter. This fixes a segmentation fault due to infinite recursion. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* asfdec_o: only set asf_pkt->data_size after sanity checksAndreas Cadhalpun2016-01-151-8/+10
| | | | | | | | Otherwise invalid values are used unchecked in the next run. This can cause NULL pointer dereferencing. Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* lavu: prevent overflow in av_clip_intp2_cAndreas Cadhalpun2016-01-151-1/+1
| | | | | | | | This fixes ubsan runtime error: signed integer overflow: 8388608 + 2140274688 cannot be represented in type 'int' Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
* lavc/aacenc: use isfinite to simplify isnan/isinf logicGanesh Ajjanagadde2016-01-141-8/+9
| | | | | Reviewed-by: Claudio Freire <klaussfreire@gmail.com> Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
* avformat/rmdec: Fix Packet memleak at close()Michael Niedermayer2016-01-141-0/+1
| | | | | | | Fixes: asan_heap-oob_445b39_1741_d00eb645ab48eb2203b4a04a5b997103.ivr Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/rmdec: Check size in ivr_read_packet() before useMichael Niedermayer2016-01-141-0/+5
| | | | | | | | Fixes out of array access Fixes: asan_heap-oob_445b39_1741_d00eb645ab48eb2203b4a04a5b997103.ivr Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/vscale: Use matching sliceY/chrSliceY for luma/chromaMichael Niedermayer2016-01-141-7/+7
| | | | | | No case known where that makes a difference Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* lavc/ccaption_dec: clear all unused rows during rollupAman Gupta2016-01-141-1/+4
| | | | | | Sometimes rollup captions can move around the screen. This fixes "ghost" captions from below the current rollup area from continuing to be captured when a rollup moves higher up on the screen.
* lavc/ccaption_dec: clean up whitespaceAman Gupta2016-01-141-2/+1
|
* fate: add test for realtime ccaption decoderAman Gupta2016-01-142-0/+45
|
* lavc/ccaption_dec: implement real_time optionAman Gupta2016-01-141-8/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This new mode is useful for realtime decoding of closed captions so they can be display along with mpeg2 frames. Closed caption streams contain two major types of captions: - POPON captions, which are buffered off-screen and displayed only after EOC (end of caption, aka display buffer) - PAINTON/ROLLUP captions, which are written to the display as soon as they arrive. In a typical real-time eia608 decoder, commands like EOC (end of caption; display buffer), EDM (erase display memory) and EBM (erase buffered memory) perform their expected functions as soon as the commands are processed. This is implemented in the real_time branches added in this commit. Before this commit, and in the !real_time branches after this commit, the decoder cleverly implements its own version of the decoder which is specifically geared towards buffered decoding. It does so by actively ignoring commands like EBM (erase buffered memory), and then re-using the non-display buffer to hold the previous caption while the new one is received. This is the opposite of the real-time decoder, which uses the non-display buffer to hold the new caption while the display buffer is still showing the current caption. In addition to ignoring EBM, the buffered decoder also has custom implementations for EDM and EOC. An EDM (erase display memory) command flushes the existing contents before clearing the screen, and EOC similarly always flushes the active buffer (the previous subtitle) before flipping buffers.
* avfilter/vf_fftfilt: this is video filter so use pixels instead of samplesPaul B Mahol2016-01-141-1/+1
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/vf_fftfilt: use the name 's' for the pointer to the private contextPaul B Mahol2016-01-141-72/+72
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* lavc/ccaption_dec: flush context on seekAman Gupta2016-01-141-0/+19
|
* swscale/vscale: Check that 2 tap filters are bilinear before using bilinear codeMichael Niedermayer2016-01-142-7/+26
| | | | | | | | Fixes: out of array reads Fixes: 07e8b9c5d348ccdf7add0f37de20cf6c/asan_heap-oob_27e8df7_6849_e56653f768070ec8cb52f587048444c2.mov Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/output: Assert that yalpha and uvalpha are within their expected rangeMichael Niedermayer2016-01-141-0/+16
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/vscale: Add fixme comment to "ugly" codeMichael Niedermayer2016-01-141-1/+1
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/slice: Fix indentionMichael Niedermayer2016-01-141-6/+6
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale/slice: Fix doc typoMichael Niedermayer2016-01-141-1/+1
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale: Move Contexts used only in hscale.c into itMichael Niedermayer2016-01-142-15/+15
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* swscale: Move VScalerContext into vscale.cMichael Niedermayer2016-01-142-9/+10
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>