Commit Graph

19640 Commits

Author SHA1 Message Date
Anton Khirnov
17ba719d9b mmvideo: check frame dimensions
The frame size must be set by the caller and each dimension must be a
multiple of 2.

CC: libav-stable@libav.org
Bug-ID: CVE-2014-8543
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2014-12-19 08:01:46 +01:00
Anton Khirnov
88626e5af8 jvdec: check frame dimensions
The frame size must be set by the caller and each dimension must be a
multiple of 8.

CC: libav-stable@libav.org
Bug-ID: CVE-2014-8542
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2014-12-19 08:01:46 +01:00
Anton Khirnov
809c3023b6 mjpegdec: check for pixel format changes
Fixes possible invalid memory access.

Based on code by Michael Niedermayer <michaelni@gmx.at>

CC: libav-stable@libav.org
Bug-ID: CVE-2014-8541
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2014-12-19 08:01:46 +01:00
Vittorio Giovara
210461c0a8 imgconvert: check memory allocations and propagate errors 2014-12-18 23:27:14 +01:00
Vittorio Giovara
596b5c488f wma: check memory allocations and propagate errors 2014-12-18 23:27:14 +01:00
Vittorio Giovara
5ac06633cb takdec: check av_samples_get_buffer_size() return value
CC: libav-stable@libav.org
Bug-Id: CID 747734
2014-12-18 23:27:14 +01:00
Vittorio Giovara
16c7a8a142 aacps: invert the order of parameters of ipdopd_reset()
This is the order that the caller uses in the rest of the file. The
same operation is applied to both parameters, so this change is only
done for consistency, it doesn't change the actual behaviour.

Bug-Id: CID 732285 / CID 732286
2014-12-18 23:27:14 +01:00
Vittorio Giovara
9745f19ffc assdec: check the right variable
CC: libav-stable@libav.org
Bug-Id: CID 1257815
2014-12-18 23:27:14 +01:00
Vittorio Giovara
971099ff5a aacenc: correctly check returned value
CC: libav-stable@libav.org
2014-12-18 23:27:14 +01:00
Vittorio Giovara
ac467d94fa lcl: return an appropriate error code 2014-12-18 23:27:14 +01:00
Vittorio Giovara
c63dd3f0a4 a64multi: check elbg return values 2014-12-18 23:22:59 +01:00
Vittorio Giovara
3beb9cbad3 roqvideo: check memory allocations and propagate errors 2014-12-18 23:22:59 +01:00
Vittorio Giovara
ae2d41ec87 elbg: check memory allocations and propagate errors 2014-12-18 23:22:59 +01:00
Vittorio Giovara
67fc8a15e4 theora: support different visible and coded frame size
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-18 23:22:59 +01:00
Paul B Mahol
87bd298abe DPX parser
Additional improvements and fixes by Michael Niedermayer <michaelni@gmx.at>.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-18 23:22:59 +01:00
Carl Eugen Hoyos
3a3790b8f8 tiff: support encoding and decoding 64bit images 2014-12-18 23:22:59 +01:00
Michael Niedermayer
3bb465245f h261dec: Fix context initialization sequence
ff_mpv_common_init sets s->context_initialized.

This fixes decoding of h261 in the cases where the demuxer
hasn't already set the frame size.

CC: libav-stable@libav.org
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 23:10:24 +02:00
Martin Storsjö
91bfac759d h261enc: Disallow sliced encoding
This avoids trying to do sliced encoding, even if a slice/packet
size is requested (via the -ps option or the rtp_payload_size
field), since the encoder currently doesn't support it (or at least
our decoder can't decode it, even if the h261_encode_gob_header
function is hooked up to be called from the slicing part in
mpegvideo_enc.c).

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 12:00:01 +02:00
Vittorio Giovara
10d4c5e55e tiff: set the correct return value when check_size() fails
Only one instance affected and solved as other occurences.
2014-12-15 15:46:34 +01:00
Luca Barbato
3c27275c13 tiff: Check the check_size() return value and forward it
Also use the same type for add_entry and check_size.

Bug-Id: CID 700699
CC: libav-stable@libav.org

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Vittorio Giovara <vittorio.giovarao@gmail.com>
2014-12-15 15:46:34 +01:00
Luca Barbato
4690e01c3a prores: Evaluate all the quantizers
Prevent an uninitialized data access.

CC: libav-stable@libav.org
Bug-Id: CID 703824 / CID 703825
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-12-15 15:46:34 +01:00
Vittorio Giovara
d75190aa93 mpegvideo: move REBASE_PICTURE where it is used
Drop an unused #undef from h264 decoder.
2014-12-15 15:46:34 +01:00
Vittorio Giovara
63fcedcf01 mpegvideo: remove unused function declaration 2014-12-15 15:46:34 +01:00
Vittorio Giovara
b2bece5e9a hevc: always clip luma_log2_weight_denom
Its value shall be between 0 and 7 according to the specifications.

CC: libav-stable@libav.org
Bug-Id: CID 1257502
2014-12-15 15:46:34 +01:00
Thiago Santos
bab8d73765 vaapi: wrap codec specific functions in appropiate #ifs
Fix linking when only a subset of vaapi decoders is enabled.

Bug-Id: 760
CC: libav-stable@libav.org

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-12-14 22:04:38 +01:00
Michael Niedermayer
5a82ad644f svq1dec: Unbreak the scratch buffer allocation
The input packets are always assumed to be padded and
the av_fast_ family of function takes a pointer to a pointer.

Thanks to Nicolas Dufresne <nicolas.dufresne@collabora.com> for
a similar patch.

Introduced in 7b588bb691.

Bug-Id: 766
CC: libav-stable@libav.org
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-12-14 22:03:58 +01:00
Luca Barbato
bcbdeb318e asvenc: Forward the error instead of asserting on it
Bug-Id: CID 732997
CC: libav-stable@libav.org
2014-12-14 22:03:22 +01:00
Rémi Denis-Courmont
559fa0d41b vdpau: add mapping for H.264 Constrained Baseline profile and fallback
Old VDPAU drivers do not support this newly defined profile, so falling
back to Main profile is necessary for backward binary compatibility.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-12-14 18:30:03 +01:00
Rémi Denis-Courmont
8502c1e9ff vdpau: add mapping for H.264 Extended profile
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-12-14 18:29:27 +01:00
Rémi Denis-Courmont
8b51bcfed7 vdpau: revector macro to reduce line span
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-12-14 18:29:07 +01:00
Martin Storsjö
c7921a4804 libfdk-aacdec: Fix a boundary check
This avoids potential out of bounds writes, with potential future
versions of the library.

Bug-Id: CID 1254945
CC: libav-stable@libav.org
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-10 22:51:42 +02:00
Janne Grunau
4c81613df4 arm: mlpdsp: handle pic offset calculation in a macro
Makes the code easier to read since it hides different offset
calculations for arm and thumb mode.
2014-12-09 22:00:08 +01:00
Janne Grunau
581c7f0e12 arm: make ff_mlp_filter_channel_arm and ff_mlp_rematrix_channel_arm position independent
No significant difference in used cpu cycles on a cortex-a9.
2014-12-09 22:00:08 +01:00
Martin Storsjö
780cd20b00 aarch64: Use .data.rel.ro for const data with relocations
This reverts commit c00365b46d
in addition to using a different section.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-09 11:43:31 +02:00
Martin Storsjö
f963f80399 arm: Use .data.rel.ro for const data with relocations
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-09 11:43:25 +02:00
Vittorio Giovara
6fd91fa119 h264: increase MAX_SLICES to 32
H264 streams from CounterPath Bria and some Cisco phones need an
increased pool for correct decoding.

Bug-Id: 645
Sample-Id: bria-h264.mka
2014-12-08 13:30:38 +00:00
Zoltan Kovacs
4843a9c74f dpx: always write the image offset
According to the DPX file format description found at
http://www.fileformat.info/format/dpx/egff.htm the ImageElement part of
the GenericImageHeader also contains an an offset to the real image data
beside the same member that can be found in the GenericFileHeader.

Libav keeps this member empty (=0) while some applications expects it to
be filled properly. FATE test updated accordingly.

Bug-Id: 742
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-08 13:29:18 +00:00
Martin Storsjö
b280c6202b arm: fft_vfp: Unify the behaviour in ff_fft_calc_vfp between arm/thumb
Don't include the function pointer table in the code segment
in arm mode.

This shouldn't have any significant performance effect. It does
end up as a few more instructions than before, for ARM, but
only at the entry to this function, not within the fft functions
themselves.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-08 12:29:53 +02:00
Martin Storsjö
ae81576414 arm: fft_vfp: Add a missing "endconst" when building in thumb mode
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-08 12:29:49 +02:00
Kieran Kunhya
9a738c27dc v210enc: Add SIMD optimised 8-bit and 10-bit encoders
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-05 13:03:49 +00:00
Vittorio Giovara
b72727a524 lavc: mention that the parser callback never returns an error 2014-12-05 00:44:42 +00:00
Michael Niedermayer
894545cb71 mpegvideo: exit cleanly when ff_mpv_common_frame_size_change() fails
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-03 12:52:53 +00:00
Michael Niedermayer
7a38987f24 mpegvideo: free_context_frame() cannot fail, make it return void
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-03 12:52:04 +00:00
Michael Niedermayer
c45eeb2dbf mpegvideo: replace assert about interlaced EC with debug av_log()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-03 12:51:43 +00:00
Michael Niedermayer
3a56bcee7c mpeg12dec: Use more specific error codes
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-03 12:50:52 +00:00
Michael Niedermayer
b56afb48ae mpeg12dec: Print error/warning messages on issues in mpeg1_decode_sequence()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-03 12:44:58 +00:00
Gonzalo Garramuno
e0bb74a140 exr: Add a gamma flag to exr loader to avoid banding
This is needed to avoid banding artifacts when gammaing the picture.
Currently, if done with a video filter, the process is done on uints
instead of full float.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-03 02:55:40 +00:00
Michael Niedermayer
d69d787dad h264: proper cleanup in ff_h264_alloc_tables() if DPB alloc fails
CC: libav-devel@libav.org
2014-12-03 02:51:27 +00:00
Dale Curtis
56de2897a6 h264: Fix memory leak on ff_h264_decode_init() failure
CC: libav-devel@libav.org
2014-12-03 02:51:18 +00:00
Jon Morley
26e20dfd06 options_table: fix colorspace minimum option value
The min value for colorspace should be zero and not one since the first
valid index into the frame colorspace array is AVCOL_SPC_RGB which is 0.
2014-12-02 15:28:22 +00:00