Carl Eugen Hoyos [Tue, 19 Jan 2016 10:02:14 +0000 (11:02 +0100)]
ape: Show more information for loglevel verbose.
Requested by Andy E, fixes bug 687.
Hendrik Leppkes [Tue, 19 Jan 2016 07:58:55 +0000 (08:58 +0100)]
Merge commit '
7570c9e04f010c9b3bfdeb4338d330f2cdd25278'
* commit '
7570c9e04f010c9b3bfdeb4338d330f2cdd25278':
swfdec: support compressed swf
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:53:58 +0000 (08:53 +0100)]
Merge commit '
34d45b36164eee044cfe55d22488b2b65e387872'
* commit '
34d45b36164eee044cfe55d22488b2b65e387872':
asfdec: Fix typo in comment
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:53:43 +0000 (08:53 +0100)]
Merge commit '
40d43d25e76ca078e7665752e815fc8d96252f06'
* commit '
40d43d25e76ca078e7665752e815fc8d96252f06':
APIchanges: Add missing av_pix_fmt_get_chroma_sub_sample entry
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:51:12 +0000 (08:51 +0100)]
Merge commit '
73c8c0341cce9e1a6c4169721f5123f97fc4be2f'
* commit '
73c8c0341cce9e1a6c4169721f5123f97fc4be2f':
arm: Fix vfp dead code elimination with have_vfp_vm
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:50:44 +0000 (08:50 +0100)]
Merge commit '
fec76cd430f3c865183a6e5b4caec0743e055605'
* commit '
fec76cd430f3c865183a6e5b4caec0743e055605':
checkasm: Check register clobbering on aarch64
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:49:27 +0000 (08:49 +0100)]
Merge commit '
26ec75aec3576daea691dee53a78ec67c0dc4040'
* commit '
26ec75aec3576daea691dee53a78ec67c0dc4040':
checkasm: Check register clobbering on arm
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:48:03 +0000 (08:48 +0100)]
Merge commit '
fa463aa83a4920b0eed47ad1f79775dfc53d21ec'
* commit '
fa463aa83a4920b0eed47ad1f79775dfc53d21ec':
avpacket: fix size check in packet_alloc
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:47:48 +0000 (08:47 +0100)]
Merge commit '
066281372d90d63ca021b659abcb8faefd6bc4a6'
* commit '
066281372d90d63ca021b659abcb8faefd6bc4a6':
asfdec: Remove unused function parameters
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:45:48 +0000 (08:45 +0100)]
Merge commit '
2aec600ae7af7d46a4877b5ccc263b39f05a91cb'
* commit '
2aec600ae7af7d46a4877b5ccc263b39f05a91cb':
asfdec: reject size > INT64_MAX in asf_read_unknown
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:45:38 +0000 (08:45 +0100)]
Merge commit '
c69461d73797e02e7a3ab4316050c241fa91f53f'
* commit '
c69461d73797e02e7a3ab4316050c241fa91f53f':
asfdec: only set asf_pkt->data_size after sanity checks
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:44:50 +0000 (08:44 +0100)]
Merge commit '
d1cd20e4e33f8139e150034b3c457302312d81bd'
* commit '
d1cd20e4e33f8139e150034b3c457302312d81bd':
qsvenc: split encoding frames and reading from the async FIFO
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:43:03 +0000 (08:43 +0100)]
Merge commit '
a6259a6ecbad18d58085e4ab23f56151e98d7b53'
* commit '
a6259a6ecbad18d58085e4ab23f56151e98d7b53':
qsvenc: properly handle the warning from MFXVideoCORE_SyncOperation
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:41:32 +0000 (08:41 +0100)]
Merge commit '
63f7f8d1dbf6ce27440fdd56ef38c822fb11b9c2'
* commit '
63f7f8d1dbf6ce27440fdd56ef38c822fb11b9c2':
avconv: Drop an impossible check
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
Hendrik Leppkes [Tue, 19 Jan 2016 07:40:32 +0000 (08:40 +0100)]
Merge commit '
7ebf1b4adad40e2b0d88ebd5cfde821a7a0ceab2'
* commit '
7ebf1b4adad40e2b0d88ebd5cfde821a7a0ceab2':
avconv: Simplify poll_filters() return value check
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
James Almer [Mon, 18 Jan 2016 19:25:11 +0000 (16:25 -0300)]
configure: disable -Wunused-const-variable
The option became too aggressive with GCC 6, generating nearly 500
warnings from static const variables defined in assorted headers
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
Michael Niedermayer [Mon, 18 Jan 2016 18:20:03 +0000 (19:20 +0100)]
avcodec/gif: Fix lzw buffer size
Fixes out of array access
Fixes:
aaa479088e6fb40b04837b3119f47b04/asan_heap-oob_e38c68_8576_9d653078b2470700e2834636f12ff557.tga
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Mon, 18 Jan 2016 16:13:55 +0000 (17:13 +0100)]
avcodec/put_bits: Assert buf_ptr in flush_put_bits()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Paul B Mahol [Mon, 18 Jan 2016 18:38:14 +0000 (19:38 +0100)]
avfilter/avf_showfreqs/showspectrum: rename skip_samples to hop_size
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Ronald S. Bultje [Sat, 16 Jan 2016 19:44:28 +0000 (14:44 -0500)]
videodsp: fix 1-byte overread in top/bottom READ_NUM_BYTES iterations.
This can overread (either before start or beyond end) of the buffer in
Nx1 (i.e. height=1) images.
Fixes mozilla bug
1240080.
Mats Peterson [Sun, 17 Jan 2016 21:27:52 +0000 (22:27 +0100)]
lavc/rawdec: Use AV_PIX_FMT_PAL8 for 1-bit raw QuickTime video
Match the use of AV_PIX_FMT_PAL8 for 1-bit QuickTime Animation in
lavc/qtrle. To reiterate, 1-bit video is not necessary black & white in
QuickTime, merely bi-level. The two colors can be any color. The palette,
either included in the sample description, or the default Macintosh
palette (black & white for 1-bit video) will be set in lavf/qtpalette.
See the QuickTime File Format Specification for details.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Paul B Mahol [Sun, 17 Jan 2016 10:13:33 +0000 (11:13 +0100)]
doc/filters: add yet another fftfilt example
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Michael Niedermayer [Mon, 18 Jan 2016 02:31:25 +0000 (03:31 +0100)]
avcodec/tiff: Check subsample & rps values more completely
Fixes out of array access
Fixes:
83aedfb29af669c4d6e10f1bfad974d2/asan_heap-oob_1ab42fe_4984_9f6ec14462f8d8a00ea24b320572a963.tif
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Carl Eugen Hoyos [Sun, 17 Jan 2016 23:36:44 +0000 (00:36 +0100)]
lavf/icodec: Improve autodetection.
Avoids misdetection of MPEG (B-)frames.
Reviewed-by: Michael Bradshaw
James Darnley [Sun, 17 Jan 2016 20:20:25 +0000 (21:20 +0100)]
avcodec/v210: guard new avx2 functions from old assemblers
Michael Niedermayer [Sun, 17 Jan 2016 17:57:01 +0000 (18:57 +0100)]
swscale/swscale: Add some sanity checks for srcSlice* parameters
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Sun, 17 Jan 2016 17:01:33 +0000 (18:01 +0100)]
avcodec/libaacplus: Cleanup in case of init failure
Fixes: memleak
Fixes:
6b343214a0c12d94c1ea0ae9c3102dba/signal_sigsegv_262857d_8792_71ba605ad9ca9068b8218a6ce3628c25.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Carl Eugen Hoyos [Sun, 17 Jan 2016 17:37:01 +0000 (18:37 +0100)]
configure: The XMA decoders depend on wmapro.
Fixes compilation with --disable-fft.
Michael Niedermayer [Wed, 13 Jan 2016 22:51:47 +0000 (23:51 +0100)]
avcodec/diracdec: Fix qfactor/offset tables
It seems the previous tables where calculated with 32bit integers ignoring
overflows.
Also check for the max qindex, the value is choosen so that the qfactor/offset
fit in int32.
Fixes:
070b7914fd5dfe8f93248bea71363410/asan_static-oob_c8d034_2764_258e20f4a3c79158aecddb61a833d756.drc
Fixes out of array reads
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Claudio Freire [Sun, 17 Jan 2016 16:14:24 +0000 (13:14 -0300)]
libavcodec/aacenc_tnc.c: remove unused variable w2
No longer needed since previous commit
Claudio Freire [Sun, 17 Jan 2016 02:02:41 +0000 (23:02 -0300)]
AAC encoder: TNS fixes on short windows
TNS was computing filter coefficients incorrectly for short windows
due to a few coefficient addressing bugs. Fixing them fixes lots of
instability with transients (short windows).
Claudio Freire [Sat, 16 Jan 2016 23:47:00 +0000 (20:47 -0300)]
AAC encoder: use signed coeffs when measuring IS energy
I/S energy, especially when it comes to phase cancellations,
needs to use signed coefficients as input, yet it was using
abs'd coefficients. That was a slight bug.
Claudio Freire [Sat, 16 Jan 2016 23:44:36 +0000 (20:44 -0300)]
AAC encoder: enforce SF delta in PNS and IS SFs
Make sure to properly enforce maximum scalefactor delta in PNS
and I/S, not as an absolute range but relative to the previous
and first scalefactor, the latter important since PNS uses an
implicit inicial scalefactor derived from the global gain, and
encoded in a different way, which makes a big difference in the
allowed range.
James Darnley [Fri, 15 Jan 2016 18:53:28 +0000 (19:53 +0100)]
avcodec/v210: document the requirement for sample_factor
The sample factor must be the same for both 8- and 10-bit functions chosen
otherwise the output will be incorrect.
James Darnley [Fri, 15 Jan 2016 18:30:03 +0000 (18:30 +0000)]
avcodec/v210: add avx2 version of the 10-bit line encoder
Around 25% faster than the ssse3 version.
James Darnley [Wed, 30 Dec 2015 17:20:59 +0000 (17:20 +0000)]
avcodec/v210: add avx2 version of the 8-bit line encoder
Around 35% faster than the avx version.
Signed-off-by: Henrik Gramner <henrik@gramner.com>
James Darnley [Fri, 15 Jan 2016 16:29:28 +0000 (16:29 +0000)]
fate: add 10-bit v210 encoder tests
Michael Niedermayer [Sun, 17 Jan 2016 11:33:50 +0000 (12:33 +0100)]
swscale/x86/rgb2rgb_template: Fix planar2x() for short width
Fixes:
451b3e0cf956c0bd2f27ed753ac24050/asan_heap-oob_2873c01_3231_7ed10a9464d15f0d57277f5917c566a8.AVI
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Eddie Hao [Sun, 17 Jan 2016 05:41:54 +0000 (21:41 -0800)]
remove all uses of the deprecated avpicture_get_size() function
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Sat, 16 Jan 2016 23:55:44 +0000 (00:55 +0100)]
swscale/swscale_unscaled: Fix odd height inputs for bayer_to_yv12_wrapper()
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>
Michael Niedermayer [Sat, 16 Jan 2016 23:55:44 +0000 (00:55 +0100)]
swscale/swscale_unscaled: Fix odd height inputs for bayer_to_rgb24_wrapper()
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>
Michael Niedermayer [Sat, 16 Jan 2016 22:14:51 +0000 (23:14 +0100)]
ffmpeg: fix sws_dict leak on error exit
Fixes:
1b79b985cdf860ffa228c00ee5497051/signal_sigsegv_1f99d24_3549_86d92054a79f6ff900fbaf03f8012b32.aif
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
James Almer [Sat, 16 Jan 2016 01:04:09 +0000 (22:04 -0300)]
x86/fixed_dsp: add ff_butterflies_fixed_sse2
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
Michael Niedermayer [Sat, 16 Jan 2016 20:40:49 +0000 (21:40 +0100)]
avcodec/wmaenc: Check input for finiteness
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>
Michael Niedermayer [Sat, 16 Jan 2016 17:32:07 +0000 (18:32 +0100)]
avcodec/aacenc: Check both channels for finiteness
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>
Mats Peterson [Fri, 15 Jan 2016 22:25:38 +0000 (23:25 +0100)]
lavf/matroskadec: Get sample size from private data
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Mats Peterson [Fri, 15 Jan 2016 22:28:06 +0000 (23:28 +0100)]
lavf/mov: Don't limit fourcc 0 -> raw/twos to version 0 sample descriptions
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Fri, 15 Jan 2016 22:58:51 +0000 (23:58 +0100)]
avcodec/motion_est: Attempt to fix "short data segment overflowed" on IA64
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>
Andreas Cadhalpun [Thu, 14 Jan 2016 23:17:10 +0000 (00:17 +0100)]
mpeg4videodec: silence ubsan warning
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>
Ganesh Ajjanagadde [Wed, 13 Jan 2016 22:59:26 +0000 (17:59 -0500)]
lavu/x86/lls: add fma3 optimizations for update_lls
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>
Paul B Mahol [Fri, 15 Jan 2016 20:34:05 +0000 (21:34 +0100)]
avfilter/af_sidechaincompress & af_agate: use audio fifo from lavu
Fixes regression causing segfault.
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Piotr Bandurski [Thu, 14 Jan 2016 16:01:00 +0000 (17:01 +0100)]
avformat/riff: add C210 FourCC (Canopus C210)
Piotr Bandurski [Thu, 14 Jan 2016 17:38:08 +0000 (18:38 +0100)]
avformat/riff: add YUYV FourCC (Drastic YUYV)
Paul B Mahol [Tue, 29 Dec 2015 20:22:26 +0000 (21:22 +0100)]
avfilter: add ahistogram multimedia filter
Signed-off-by: Paul B Mahol <onemda@gmail.com>
James Almer [Fri, 15 Jan 2016 16:32:58 +0000 (13:32 -0300)]
x86/intmath: add missing early clobber to output operands
Signed-off-by: James Almer <jamrial@gmail.com>
Michael Niedermayer [Fri, 15 Jan 2016 16:08:37 +0000 (17:08 +0100)]
avcodec/x86/fmtconvert: Add emms to int32_to_float_fmul_array8_sse()
this should fix checkasm on x86_64-archlinux-gcc-valgrind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Fri, 15 Jan 2016 15:51:54 +0000 (16:51 +0100)]
avfilter/vaf_spectrumsynth: Fix mixed declaration and statment
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Fri, 15 Jan 2016 14:29:22 +0000 (15:29 +0100)]
avformat/hls: Even stricter URL checks
This fixes a null pointer dereference at least
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Fri, 15 Jan 2016 12:29:38 +0000 (13:29 +0100)]
avformat/hls: More strict url checks
No case is known where these are needed
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
James Almer [Fri, 15 Jan 2016 05:26:36 +0000 (02:26 -0300)]
avcodec/rmdec: add missing av_log argument
Also change the format specifier to expect an unsigned int
Signed-off-by: James Almer <jamrial@gmail.com>
Mats Peterson [Tue, 12 Jan 2016 23:32:20 +0000 (00:32 +0100)]
lavf/mov: Confine 0x00000000 to raw/twos fourcc mapping to version 0 sample 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>
Michael Niedermayer [Thu, 14 Jan 2016 23:57:00 +0000 (00:57 +0100)]
avcodec/pngenc: Fix mixed up linesizes
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>
Michael Niedermayer [Thu, 14 Jan 2016 23:35:57 +0000 (00:35 +0100)]
avcodec/pngenc: Replace memcpy by av_image_copy()
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>
Andreas Cadhalpun [Wed, 6 Jan 2016 18:21:49 +0000 (19:21 +0100)]
asfdec_o: check for too small size in asf_read_unknown
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>
Andreas Cadhalpun [Wed, 6 Jan 2016 17:44:33 +0000 (18:44 +0100)]
asfdec_o: break if EOF is reached after asf_read_packet_header
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>
Andreas Cadhalpun [Wed, 6 Jan 2016 18:03:17 +0000 (19:03 +0100)]
asfdec_o: make sure packet_size is non-zero before seeking
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>
Andreas Cadhalpun [Wed, 6 Jan 2016 13:09:22 +0000 (14:09 +0100)]
asfdec_o: prevent overflow causing seekback
This fixes infinite loops.
Reviewed-by: Alexandra Hájková <alexandra.khirnova@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Andreas Cadhalpun [Wed, 6 Jan 2016 12:54:59 +0000 (13:54 +0100)]
asfdec_o: check avio_skip in asf_read_simple_index
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>
Andreas Cadhalpun [Tue, 5 Jan 2016 12:20:11 +0000 (13:20 +0100)]
asfdec_o: reject size > INT64_MAX in asf_read_unknown
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>
Andreas Cadhalpun [Tue, 5 Jan 2016 12:06:51 +0000 (13:06 +0100)]
asfdec_o: only set asf_pkt->data_size after sanity checks
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>
Andreas Cadhalpun [Thu, 14 Jan 2016 00:15:22 +0000 (01:15 +0100)]
lavu: prevent overflow in av_clip_intp2_c
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>
Ganesh Ajjanagadde [Thu, 14 Jan 2016 22:55:56 +0000 (17:55 -0500)]
lavc/aacenc: use isfinite to simplify isnan/isinf logic
Reviewed-by: Claudio Freire <klaussfreire@gmail.com>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Michael Niedermayer [Thu, 14 Jan 2016 22:32:13 +0000 (23:32 +0100)]
avformat/rmdec: Fix Packet memleak at close()
Fixes: asan_heap-oob_445b39_1741_d00eb645ab48eb2203b4a04a5b997103.ivr
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 22:20:58 +0000 (23:20 +0100)]
avformat/rmdec: Check size in ivr_read_packet() before use
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>
Michael Niedermayer [Thu, 14 Jan 2016 21:10:08 +0000 (22:10 +0100)]
swscale/vscale: Use matching sliceY/chrSliceY for luma/chroma
No case known where that makes a difference
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Aman Gupta [Wed, 13 Jan 2016 01:27:06 +0000 (17:27 -0800)]
lavc/ccaption_dec: clear all unused rows during rollup
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.
Aman Gupta [Thu, 14 Jan 2016 21:55:07 +0000 (13:55 -0800)]
lavc/ccaption_dec: clean up whitespace
Aman Gupta [Wed, 13 Jan 2016 01:22:30 +0000 (17:22 -0800)]
fate: add test for realtime ccaption decoder
Aman Gupta [Sat, 9 Jan 2016 03:01:22 +0000 (19:01 -0800)]
lavc/ccaption_dec: implement real_time option
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.
Paul B Mahol [Thu, 14 Jan 2016 21:20:25 +0000 (22:20 +0100)]
avfilter/vf_fftfilt: this is video filter so use pixels instead of samples
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Paul B Mahol [Thu, 14 Jan 2016 21:19:52 +0000 (22:19 +0100)]
avfilter/vf_fftfilt: use the name 's' for the pointer to the private context
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Aman Gupta [Wed, 6 Jan 2016 05:46:27 +0000 (21:46 -0800)]
lavc/ccaption_dec: flush context on seek
Michael Niedermayer [Thu, 14 Jan 2016 20:33:53 +0000 (21:33 +0100)]
swscale/vscale: Check that 2 tap filters are bilinear before using bilinear code
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>
Michael Niedermayer [Thu, 14 Jan 2016 17:36:02 +0000 (18:36 +0100)]
swscale/output: Assert that yalpha and uvalpha are within their expected range
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 17:11:22 +0000 (18:11 +0100)]
swscale/vscale: Add fixme comment to "ugly" code
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 16:18:41 +0000 (17:18 +0100)]
swscale/slice: Fix indention
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 16:13:13 +0000 (17:13 +0100)]
swscale/slice: Fix doc typo
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 15:51:34 +0000 (16:51 +0100)]
swscale: Move Contexts used only in hscale.c into it
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 15:49:33 +0000 (16:49 +0100)]
swscale: Move VScalerContext into vscale.c
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Paul B Mahol [Sun, 10 Jan 2016 13:48:12 +0000 (14:48 +0100)]
avfilter: add spectrumsynth filter
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Michael Niedermayer [Thu, 14 Jan 2016 14:11:48 +0000 (15:11 +0100)]
swscale/utils: Detect and skip unneeded sws_setColorspaceDetails() calls
This avoids running various table inits unnecessarily
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 02:05:11 +0000 (03:05 +0100)]
swscale/yuv2rgb: Increase YUV2RGB table headroom
This makes SWS more robust
Fixes:
07650a772d98aa63b0fed6370dc89037/asan_heap-oob_27ddeaf_2657_2c81ff264dee5d9712cb3251fb9c3bbb.264
Fixes: out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Thu, 14 Jan 2016 11:36:41 +0000 (12:36 +0100)]
swscale/yuv2rgb: Factor YUVRGB_TABLE_LUMA_HEADROOM out
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Paul B Mahol [Thu, 14 Jan 2016 13:27:01 +0000 (14:27 +0100)]
avfilter/af_dynaudnorm: fix possible null pointer dereference
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Claudio Freire [Thu, 14 Jan 2016 03:38:22 +0000 (00:38 -0300)]
avcodec/aacenc_is: replace pow(x, 0.75) by x/sqrtf(sqrtf(x))
This is quite an accurate approximation; testing shows ~ 2ulp error in
the floating point result. Tested with FATE.
Alternatively, if one wants "full accuracy", one can use powf, or sqrt
instead of sqrtf. With powf, one gets 1 ulp error (theoretically should be 0, as
0.75 is exactly representable) on GNU libm, with sqrt, 0 ulp error.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Abstracted into pos_pow34 utility function
Signed-off-by: Claudio Freire <klaussfreire@gmail.com>
Ganesh Ajjanagadde [Thu, 14 Jan 2016 00:09:25 +0000 (19:09 -0500)]
lavu/libm: add isfinite fallback
Reviewed-by: Ronald S. Bultje <rsbultje@gmail.com>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Andreas Cadhalpun [Tue, 12 Jan 2016 23:52:58 +0000 (00:52 +0100)]
dca: fix misaligned access in avpriv_dca_convert_bitstream
src and dst are only 8-bit-aligned, so accessing them as uint16_t causes
SIGBUS crashes on architectures like sparc.
This fixes ubsan runtime error: load of misaligned address for type
'const uint16_t', which requires 2 byte alignment
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Maxim Andreev [Wed, 13 Jan 2016 08:51:12 +0000 (11:51 +0300)]
avformat/hls: forbid all protocols except http(s) & file
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Michael Niedermayer [Wed, 13 Jan 2016 21:33:59 +0000 (22:33 +0100)]
avcodec/aacenc: Check for +-Inf too
Fixes out of array read
Fixes:
04442da73d935b776d2236282588d4f9/signal_sigsegv_2625a69_8790_ae85ffc889070663319b3417ede777b0.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
James Almer [Wed, 13 Jan 2016 22:26:40 +0000 (19:26 -0300)]
avcodec/wavpackenc: print channel count in av_log call
Fixes a warning with -Wformat-extra-args