aboutsummaryrefslogtreecommitdiffstats
path: root/libswresample
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-04-10 19:53:11 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-04-10 19:54:42 +0200
commit7c673d73ec0bcb79262cbef503ab6fe0bf8ad000 (patch)
tree20d70c8bf79b645e4e9199841dc121468b46f704 /libswresample
parentdb2eadb2f57ad5a580c9ad5b2d288c4f6a2eeecb (diff)
downloadffmpeg-7c673d73ec0bcb79262cbef503ab6fe0bf8ad000.tar.gz
swr: use assert in swri_sum2 to check that only supported formats are used.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libswresample')
-rw-r--r--libswresample/rematrix.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libswresample/rematrix.c b/libswresample/rematrix.c
index 1dc8ffbaa4..845f854335 100644
--- a/libswresample/rematrix.c
+++ b/libswresample/rematrix.c
@@ -276,6 +276,7 @@ void swri_sum2(enum AVSampleFormat format, void *dst, const void *src0, const vo
if(format == AV_SAMPLE_FMT_FLT){
sum2_float((float *)dst, (const float *)src0, (const float *)src1, coef0, coef1, len);
}else{
+ av_assert1(format == AV_SAMPLE_FMT_S16);
sum2_s16 ((int16_t*)dst, (const int16_t*)src0, (const int16_t*)src1, lrintf(coef0 * 32768), lrintf(coef1 * 32768), len);
}
}