Fixes: af94b3a3d26586c08f557cafe8246251_signal_sigsegv_7ffff713351a_343_XFMode.ASF with 1048576 alloc limit
Found-by: Samuel Groß, Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* commit '077b55943330150db0eafd36bbee614697cabd98':
hevc: handle a NULL sps in set_sps() properly
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* commit '18156b53f9b642b71c182c5c9818175a61572d2b':
hevc: do not pass an entire HEVCContext into export_stream_params()
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
Fixes crash in 1288a2fe8e9ae6b00ca40e089d08ca65_signal_sigsegv_7ffff71426a7_354_accident.san with allocation limit 65536
Found-by: Samuel Groß, Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Fixes: 06a4edb39ad8a9883175f9bd428334a2_signal_sigsegv_7ffff713351a_706_mov__alac__ALAC_6ch.mov
Found-by: Samuel Groß, Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
internal.h is difficult to use due to circular dependancies
mem.h is a public header ff_* is not public
Alternative solutions probably are possible too
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Feel free to use either, they both work but the old one provides
more information but needs the hevc decoder
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* commit 'd82e1adc2019135a2fc45372e0ed0b5ef107cdd0':
hevc: move splitting the packet into NALUs into a separate function
Conflicts:
libavcodec/hevc.c
libavcodec/hevc.h
libavcodec/hevc_parse.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* commit 'ae05b4865514fd71b5e9431e93aa0d03d7ba7751':
hevc: eliminate the second call to hls_nal_unit()
Conflicts:
libavcodec/hevc.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* commit 'd7bebe4805193783f0b6f292f9127a75709fb7d9':
hevc: skip invalid/ignored NALUs when splitting the packet
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* commit 'ab05ed4c322ed0488ac9b5d2ef5d4ffa55a946a7':
mpegvideo_parser: export pixel format and dimensions
Conflicts:
libavcodec/mpegvideo_parser.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
* commit '86eee85daddb682fa072c2e2657c90a514b855e3':
bytestream2: set the reader to the end when reading more than available
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
This also prevents an eventual compilation failure once request_channels
is removed.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: James Almer <jamrial@gmail.com>
Also, make hls_nal_unit() work only on the provided NAL unit, without
requiring a whole decoding context.
This will allow splitting this code for reuse by the parser.
This prevents possible infinite loops with the calling code along the
lines of while (bytestream2_get_bytes_left()) { ... }, where the reader
does not advance.
CC: libav-stable@libav.org
It is used as get_bits argument and reading 0 bits doesn't make sense.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
flcoeffs2[pos] should be the log2 of flcoeffs1[pos].
flcoeffs1[0] can be 0 here, thus flcoeffs2[pos] gets set to -inf,
causing problems further down.
This seems to have been copied from imc_decode_level_coefficients in
commit 4eb4bb3 without updating the position.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
flcoeffs2[pos] should be the log2 of flcoeffs1[pos].
flcoeffs1[0] can be 0 here, thus flcoeffs2[pos] gets set to -inf,
causing problems further down.
This seems to have been copied from imc_decode_level_coefficients in
commit 4eb4bb3 without updating the position.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
It is used as get_bits argument and reading 0 bits isn't supported.
Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>