Michael Niedermayer
79cd5d39ba
avcodec/utvideodec: Fix vlc len
...
Fixes regression / Ticket2661
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
c17dd513e7
bytestream2_init: assert that buf_size is valid
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
32fc8d6db6
avcodec/jpeg2000dec: check that tp_end is after the start
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
ddefb80c95
sonicenc: fix off by 1 error
...
Fixes out of array accesses
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
694c2d1ab3
sonicenc: dont put multiple assignments per line
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
6df61c3ae0
sonicenc: set supported samples formats array
...
This ensures that only supported formats are input
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Janne Grunau
2ee380aefb
vaapi: return early from ff_vaapi_render_picture() without picture
...
Fixes an assertion when called on uninitialized frame. Spotted after
seeking in vlc.
Fixes ticket #2461 .
Tested-by: Timo
Reviewed-by: Joakim Plate
Signed-off-by: Carl Eugen Hoyos <cehoyos@ag.or.at>
12 years ago
Carl Eugen Hoyos
28bf0d94aa
Revert "vaapi: return early from ff_vaapi_render_picture() without picture"
...
This reverts commit 4cbf245f2a2cd2170ca30b0788c2af5b506fe6d6.
I messed up the author information.
12 years ago
Carl Eugen Hoyos
3cbf245f2a
vaapi: return early from ff_vaapi_render_picture() without picture
...
Fixes an assertion when called on uninitialized frame. Spotted after
seeking in vlc.
Fixes ticket #2461 .
Tested-by: Timo
Reviewed-by: Joakim Plate
12 years ago
Michael Niedermayer
582f53349e
jpeg2000dec: make cblk->length(inc)/data use consistent
...
Fixes Ticket2612
Reviewed-by: Nicolas BERTRAND <nicoinattendu@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Kostya Shishkov
bbb2945f2d
smacker: check the return value of smacker_decode_tree
...
Also prevent a memory leak.
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
12 years ago
Kostya Shishkov
f52edef301
smacker: fix an off by one in huff.length computation
...
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
12 years ago
Michael Niedermayer
3b86174290
avcodec/jpeg2000dec: move bpno check to a earlier place
...
This prevents additional integer overflows
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Janne Grunau
985f34b756
utils: fix avcodec_flush_buffers pre-reference counting compatibility
...
The to_free AVframe must be freed just like the other ones.
Indeed, the calling application may expect all frames to be
released.
(This regression caused use-after-free in VLC with hwaccel.)
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
12 years ago
Hendrik Leppkes
8962da9ec3
rawdec: allocate a buffer in the appropriate size in the copy case.
...
Otherwise the created buffer can be smaller than buf_size, which results
in buffer overreads if the original image has extra padding on every line.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Luca Barbato
f80b60ad59
bitstream: forward error values and drop few abort()
12 years ago
Luca Barbato
f776899a17
bitstream: K&R formatting cosmetics
12 years ago
Luca Barbato
9e80eda26d
h264_mp4toannexb_bsf: return a padded buffer
...
The code using the returned buffer might expect it to be
FF_INPUT_BUFFER_PADDING_SIZE padded as any other avpacket.
12 years ago
Luca Barbato
8d929afd25
h264_mp4toannexb_bsf: factor out extradata parsing
12 years ago
Michael Niedermayer
6c4516d041
avcodec/vc1dec: Check source picture availability in vc1_mc_4mv_chroma4()
...
Fixes null pointer dereference
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Luca Barbato
5d21ca4559
h264_mp4toannexb_bsf: K&R formatting cosmetics
12 years ago
Michael Niedermayer
3c4c5ca1c1
avcodec/g2meet: Check monochrome cursor width
...
Fixes out of array write
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
69e4d8e6a4
avcodec/jpeg2000dec: check len before parsing header
...
Fixes out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
5deb96c564
avcodec/jpeg2000dec: Check Psot
...
Fixes out of array read
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
7fff3df6b2
avcodec_encode_audio2: fix memleak on last padded frame
...
Regression introduced by 799f57ac96
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Hendrik Leppkes
59d3c24e28
vc1_parser: fix parsing of the frame headers in interlaced streams
...
first_pic_header_flag needs to be set to allow the parsing code to change
some stream parameters, and not error out.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
e850a064ce
jpeg2000dec: Check compno in get_coc()
...
Fixes out of array accesses
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
129edcb50f
jpeg2000dec: dont set ncomponents to an invalid value
...
Fixes out of array accesses
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Paul B Mahol
ff0bdf9375
lavc: copy AVCodecContext for threads
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
12 years ago
Michael Niedermayer
c112e36d41
flacdec: Fix used AVCodecContext
...
Fixes out of array writes with multiple threads
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
443b29e475
h264: Try parsing SPS as complete NAL in more cases
...
Fixes Ticket2580
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
8aea2f05dc
alacenc: Fix missing sign_extend()
...
Possibly fixes Ticket2497
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Luca Barbato
59d7bb99b6
4xm: check bitstream_size boundary before using it
...
Prevent buffer overread.
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
fbd0dacc8d
4xm: refactor decode_p_block
...
Directly return from code 1, 2 and 6 codepaths and simplify the
remaining one to have a single overflow check and a single call to
mcdc.
12 years ago
Luca Barbato
94aefb1932
4xm: do not overread the source buffer in decode_p_block
...
Check for out of picture macroblocks before calling mcdc.
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
be373cb50d
4xm: do not overread the prestream buffer
...
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
de2e5777e2
4xm: validate the buffer size before parsing it
...
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
145023f572
4xm: reject frames not compatible with the declared version
...
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
1f0c607560
4xm: drop pointless assert
...
Make sure the value of wlog2 is always between 0 and 3.
12 years ago
Luca Barbato
b8b809908e
4xm: forward errors from decode_p_block
...
Partially mitigate out of memory writes.
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
12 years ago
Luca Barbato
50ec1db62d
4xm: fold last_picture lazy allocation in decode_p_frame
12 years ago
Luca Barbato
e7a44f87d0
4xm: refactor fourxm_read_header
...
Split sound and video tag parsing in separate functions.
12 years ago
Luca Barbato
08859d19b4
4xm: use the correct logging context
12 years ago
Michael Niedermayer
7ad5708691
g2meet: Fix a typo in the height comparison
...
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Kostya Shishkov
7dfc3381dd
g2meet: do not leak buffers
12 years ago
Kostya Shishkov
4d960d7f60
g2meet: more graceful cursor loading
12 years ago
Kostya Shishkov
767ae86cee
g2meet: reset dimensions on header parsing errors
12 years ago
Michael Niedermayer
175e916fa2
avcodec/utils: Fix encoder allocation size
...
Fixes Ticket2645
Found-by: Darrell Walisser
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
84d3ff50cd
lavc: add a libwavpack encoder wrapper
12 years ago
Anton Khirnov
799f57ac96
lavc: use AVFrame API properly in pad_last_frame().
...
This also simplifies the code.
12 years ago