mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-24 03:59:43 +00:00
avcodec/wmalosslessdec: Fix null pointer dereference in decode_frame()
Fixes: 2018_03_23_poc.wav Found-by: GwanYeong Kim <gy741.kim@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
25abaf3545
commit
ea15915b2d
@ -1256,7 +1256,9 @@ static int decode_packet(AVCodecContext *avctx, void *data, int *got_frame_ptr,
|
||||
(frame_size = show_bits(gb, s->log2_frame_size)) &&
|
||||
frame_size <= remaining_bits(s, gb)) {
|
||||
save_bits(s, gb, frame_size, 0);
|
||||
s->packet_done = !decode_frame(s);
|
||||
|
||||
if (!s->packet_loss)
|
||||
s->packet_done = !decode_frame(s);
|
||||
} else if (!s->len_prefix
|
||||
&& s->num_saved_bits > get_bits_count(&s->gb)) {
|
||||
/* when the frames do not have a length prefix, we don't know the
|
||||
|
Loading…
Reference in New Issue
Block a user