sws/x86: add av_assert() to ensure 16bit code is used with 16bit data
authorMichael Niedermayer <michaelni@gmx.at>
Thu, 5 Jul 2012 02:39:11 +0000 (04:39 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 5 Jul 2012 02:39:11 +0000 (04:39 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libswscale/x86/swscale_mmx.c

index 5dd928a..86576bd 100644 (file)
@@ -396,6 +396,7 @@ void ff_sws_init_swScale_mmx(SwsContext *c)
         hscalefn = c->dstBpc <= 14 ? ff_hscale14to15_ ## filtersize ## _ ## opt2 : \
                                      ff_hscale14to19_ ## filtersize ## _ ## opt1; \
     } else { /* c->srcBpc == 16 */ \
+        av_assert0(c->srcBpc == 16);\
         hscalefn = c->dstBpc <= 14 ? ff_hscale16to15_ ## filtersize ## _ ## opt2 : \
                                      ff_hscale16to19_ ## filtersize ## _ ## opt1; \
     } \