avformat/pva: Make sure the header is large enough before reading the timestamp from it
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f34b5dc6d58_2674_PVA_test-partial.pva Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/pva: Make sure the first byte of pes_header_data has been initialized
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f53c1d0e95c_2674_PVA_test-partial.pva Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/smacker: check for format mismatch more completely
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f6e83322950_9769_wetlogo.smk Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/nistspheredec: initialize header_size to -1
Fixes use of uninitialized memory
This also avoids the need to check the scanf() return as the subsequent check catches it Fixes: msan_uninit-mem_7f712e4dc173_7414_nist_ulaw.nist Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f82af392dae_1848_HR060606.VMD Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/nistspheredec: check sscanf() success before using the result
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f935c3c6c1a_7413_nist_pcms8.nist Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/iff: warn about truncated input to decode_byterun() and clear remaining output
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7fe205e395ed_8988_test.iff Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
rpl: Dont fill the index with entries that failed to be parsed
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7fd10a199a3c_6204_landing.rpl Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes msan_uninit-mem_7fd4d4323ddd_2453_MUSOSP1.dxa Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f5ea8284fb7_8317_scummvm.dxa Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f5ea8284fb7_8317_scummvm.dxa Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/flashsv: check decode_hybrid() for overread
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f906558274e_268_14_244486_2009_04_28.flv Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/swfdec: clear 4 bytes at the end of a packet if they are not initialized
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f055dd0ab1b_9558_videopop_guitar_300k.swf Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes part of msan_uninit-mem_7f055dd0ab1b_9558_videopop_guitar_300k.swf Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes msan_uninit-mem_7f90d9cce964_9558_videopop_guitar_300k.swf Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/interplayvideo: Check that enough data is available for opcode_0x9
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7fd5185b45df_5895_interplay-logo-2MB.mve Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/interplayvideo: Check that enough data is available for opcode_0xA
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f90e5be6b30_3965_baldursgate_camp.mve Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/ipmovie: Check that OPCODE_SET_PALETTE size is large enough
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7fec1f40656c_4819_descent3_level5_16bit_partial.mve Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/ipmovie: Check that the OPCODE_INIT_AUDIO_BUFFERS size is large enough
Fixes use of uninitialized memory Fixes: msan_uninit-mem_7f75b03c1f19_4820_descent3_level5_16bit_partial.mve Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avformat/isom: zero MPEG4AudioConfig to avoid leaving fields uninitialized
Fixes: use of uninitialized memory Fixes: msan_uninit-mem_7f392c443e0d_1433_Crowd_Applause_01.caf Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Fixes use of uninitialized memory
Fixes msan_uninit-mem_7f4a141261de_7405_nirvana.nuv Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/dirac_dwt: initialize support value for fidelity wavelet
Avoids use of uninitialized memory Fixes: msan_uninit-mem_7f15e1988a6e_2748_RL_420p_ffdirac.drc Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Martin Storsjö [Wed, 18 Dec 2013 08:39:47 +0000 (10:39 +0200)]
png_parser: Fix parsing on big endian
Since pc.state is populated by shifting in from the end of the
32 bit word, the content within pc.state is already in native endian
and should not be read with the AV_R{L,B} functions.
This was already done correctly for state64 above.
Anssi Hannula [Tue, 17 Dec 2013 21:04:31 +0000 (23:04 +0200)]
avcodec/aacdec: default to non-wide 7.1 in non-strict mode
AAC specification has 7.1(wide) as a default layout for 8-channel
streams (channel config 7). However, at least Nero AAC encoder encodes
non-wide 7.1 streams using the default channel config 7, mapping the
side channels of the original audio stream to the second
AAC_CHANNEL_FRONT pair in the AAC stream. Similarly, e.g. FAAD decodes
the second AAC_CHANNEL_FRONT pair as side channels, therefore decoding
the incorrect streams as if they were correct (and as the encoder
intended).
FFmpeg currently decodes such files by-the-spec, i.e. after decoding the
original front pair will be in AV_CH_FRONT_x_OF_CENTER and the original
side pair will be in AV_CH_FRONT_x.
As actual intended 7.1(wide) streams are very rare while misencoded 7.1
files actually exist in the wild, default to assuming a 7.1 layout was
intended unless in strict mode.
Fixes playback of e.g. 8_Channel_ID.m4a in samples.
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Bumping libavutil requires all libraries that use libavutil to have their
major version bumped (yes breakage has been confirmed this is not a hypotheses)
One case of breakage is due to new types being added to AVOptions and
applications that linked to old libavutil and libswresample
then trying to use old libavutil (its soname changed so the old isnt updated)
and new swresample (its soame didnt change so it is updated)
the new swresample contains AVOption types that the old libavutil doesnt
know of thus the application attempting to access these avoptions
fails
AVOptions are used by all libs so the issue can potentially happen with
any other lib, libswresample was just the first that showed the problem
ive not checked if the other libs are affected currently by the same issue
or not
Also in addition to AVOptions, AVFrames are also defined in
libavutil, bumping it without all libs that use AVFrames could lead to
serious inconsistencies when 2 libs/app end up using 2 different libavutils
The alternative of bumping all is still possible after this revert, if it
turns out to be the preferred solution
This ensures that no mvs are uninitialized at the time of loop filtering Fixes: msan_uninit-mem_7f0b6dfe293c_2786_SA20021.vc1 Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Tables are always allocated now with sufficient space for either progressive
or interlaced content. The alternative would be to detect a change
and reallocate.