diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-09-14 11:05:54 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-09-14 11:06:02 +0200 |
commit | e27bc85b31eec26f6dca2536d8057f6f9ebaac41 (patch) | |
tree | 57427a4fd6fd6af355990092e35650d2e121019f /libavcodec | |
parent | 3f4fb49d1b14a849cbf5ebcd00bb0dba665b72a8 (diff) | |
parent | 09a098fb8bc7d70a0258b3e8d658833c8d11debe (diff) | |
download | ffmpeg-e27bc85b31eec26f6dca2536d8057f6f9ebaac41.tar.gz |
Merge commit '09a098fb8bc7d70a0258b3e8d658833c8d11debe' into release/0.10
* commit '09a098fb8bc7d70a0258b3e8d658833c8d11debe':
atrac3: fix error handling
qdm2: check and reset dithering index per channel
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/atrac3.c | 3 | ||||
-rw-r--r-- | libavcodec/qdm2.c | 3 |
2 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/atrac3.c b/libavcodec/atrac3.c index e88c7eefd9..460afbe77c 100644 --- a/libavcodec/atrac3.c +++ b/libavcodec/atrac3.c @@ -690,7 +690,8 @@ static int decodeChannelSoundUnit (ATRAC3Context *q, GetBitContext *gb, channel_ if (result) return result; pSnd->numComponents = decodeTonalComponents (gb, pSnd->components, pSnd->bandsCoded); - if (pSnd->numComponents == -1) return -1; + if (pSnd->numComponents < 0) + return pSnd->numComponents; numSubbands = decodeSpectrum (gb, pSnd->spectrum); diff --git a/libavcodec/qdm2.c b/libavcodec/qdm2.c index be8754103e..72d4a1a325 100644 --- a/libavcodec/qdm2.c +++ b/libavcodec/qdm2.c @@ -784,8 +784,6 @@ static void synthfilt_build_sb_samples (QDM2Context *q, GetBitContext *gb, int l } for (sb = sb_min; sb < sb_max; sb++) { - FIX_NOISE_IDX(q->noise_idx); - channels = q->nb_channels; if (q->nb_channels <= 1 || sb < 12) @@ -809,6 +807,7 @@ static void synthfilt_build_sb_samples (QDM2Context *q, GetBitContext *gb, int l } for (ch = 0; ch < channels; ch++) { + FIX_NOISE_IDX(q->noise_idx); zero_encoding = (BITS_LEFT(length,gb) >= 1) ? get_bits1(gb) : 0; type34_predictor = 0.0; type34_first = 1; |