diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-05-03 21:02:32 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-05-03 21:02:32 +0200 |
commit | 27744fe439c59182e608c381928817d64bb21d96 (patch) | |
tree | 62b70361f060197a5f8fc961cea0877c0df443d5 /libavcodec/wmalosslessdec.c | |
parent | af58a77f0a9760c97c736bb54ae2884dcf73cf4f (diff) | |
parent | 1d4a01474d54a4d3bb59dc94d285334f7bcbd889 (diff) | |
download | ffmpeg-27744fe439c59182e608c381928817d64bb21d96.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
mpeg12: fixed parsing in some mpeg2 streams
Add SMPTE240M transfer characteristics flag.
mpegts: Some additional HDMV types and reg descriptors for mpegts
motionpixels: Clip YUV values after applying a gradient.
jpeg: handle progressive in second field of interlaced.
ituh263dec: Implement enough of Annex O (scalability) to fix a FPE.
h263: more strictly forbid frame size changes with frame-mt.
h264: additional protection against unsupported size/bitdepth changes.
tta: prevents overflows for 32bit integers in header.
configure: remove malloc_aligned.
vp8: update frame size changes on thread context switches.
snowdsp: explicitily state instruction size.
wmall: fix reconstructing audio with uncoded channels
WMAL cosmetics: fix indentation
gitignore: add Win32 library suffixes
Conflicts:
configure
libavcodec/h263dec.c
libavcodec/h264.c
libavcodec/ituh263dec.c
libavcodec/mjpegdec.c
libavcodec/wmalosslessdec.c
libavcodec/x86/snowdsp_mmx.c
libavformat/mpegts.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/wmalosslessdec.c')
-rw-r--r-- | libavcodec/wmalosslessdec.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/libavcodec/wmalosslessdec.c b/libavcodec/wmalosslessdec.c index 48b767b18a..879bfb6d0e 100644 --- a/libavcodec/wmalosslessdec.c +++ b/libavcodec/wmalosslessdec.c @@ -793,7 +793,7 @@ static void revert_inter_ch_decorr(WmallDecodeCtx *s, int tile_size) { if (s->num_channels != 2) return; - else { + else if (s->is_channel_coded[0] || s->is_channel_coded[1]) { int icoef; for (icoef = 0; icoef < tile_size; icoef++) { s->channel_residues[0][icoef] -= s->channel_residues[1][icoef] >> 1; @@ -959,8 +959,9 @@ static int decode_subframe(WmallDecodeCtx *s) else use_normal_update_speed(s, i); revert_cdlms(s, i, 0, subframe_len); - } else - memset(s->channel_residues[i], 0, sizeof(s->channel_residues[i])); + } else { + memset(s->channel_residues[i], 0, sizeof(**s->channel_residues) * subframe_len); + } } if (s->do_mclms) revert_mclms(s, subframe_len); @@ -1217,7 +1218,7 @@ static int decode_packet(AVCodecContext *avctx, void *data, int *got_frame_ptr, /* decode the cross packet frame if it is valid */ if (num_bits_prev_frame < remaining_packet_bits && !s->packet_loss) - decode_frame(s); + decode_frame(s); } else if (s->num_saved_bits - s->frame_offset) { av_dlog(avctx, "ignoring %x previously saved bits\n", s->num_saved_bits - s->frame_offset); |