diff options
author | Paul B Mahol <onemda@gmail.com> | 2013-07-26 18:32:27 +0000 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2013-07-26 18:32:27 +0000 |
commit | 1fa0284c57fd8d5a1e098360f26e41b35f47bd36 (patch) | |
tree | e9c3349927a68727d0b81c99a0b291664935ad5d | |
parent | fdf9296df7f5145de3bc0a0564897d9c3db5848b (diff) | |
download | ffmpeg-1fa0284c57fd8d5a1e098360f26e41b35f47bd36.tar.gz |
qcelpdec: change asserts to av_asserts
Signed-off-by: Paul B Mahol <onemda@gmail.com>
-rw-r--r-- | libavcodec/qcelpdec.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/libavcodec/qcelpdec.c b/libavcodec/qcelpdec.c index 806ec65f78..607704df8c 100644 --- a/libavcodec/qcelpdec.c +++ b/libavcodec/qcelpdec.c @@ -29,6 +29,7 @@ #include <stddef.h> +#include "libavutil/avassert.h" #include "libavutil/channel_layout.h" #include "libavutil/float_dsp.h" #include "avcodec.h" @@ -40,9 +41,6 @@ #include "acelp_vectors.h" #include "lsp.h" -#undef NDEBUG -#include <assert.h> - typedef enum { I_F_Q = -1, /**< insufficient frame quality */ SILENCE, @@ -135,7 +133,7 @@ static int decode_lspf(QCELPContext *q, float *lspf) } else { erasure_coeff = QCELP_LSP_OCTAVE_PREDICTOR; - assert(q->bitrate == I_F_Q); + av_assert2(q->bitrate == I_F_Q); if (q->erasure_count > 1) erasure_coeff *= q->erasure_count < 4 ? 0.9 : 0.7; @@ -239,7 +237,7 @@ static void decode_gain_and_index(QCELPContext *q, float *gain) av_clip((q->prev_g1[0] + q->prev_g1[1]) / 2 - 5, 0, 54); subframes_count = 8; } else { - assert(q->bitrate == I_F_Q); + av_assert2(q->bitrate == I_F_Q); g1[0] = q->prev_g1[1]; switch (q->erasure_count) { @@ -486,7 +484,7 @@ static void apply_pitch_filters(QCELPContext *q, float *cdn_vector) else max_pitch_gain = 0.0; } else { - assert(q->bitrate == SILENCE); + av_assert2(q->bitrate == SILENCE); max_pitch_gain = 1.0; } for (i = 0; i < 4; i++) |