Fix the self tests which are contained in some codecs and are using random().
authorPanagiotis Issaris <takis.issaris@uhasselt.be>
Thu, 19 Jul 2007 08:47:07 +0000 (08:47 +0000)
committerPanagiotis Issaris <takis.issaris@uhasselt.be>
Thu, 19 Jul 2007 08:47:07 +0000 (08:47 +0000)
Originally committed as revision 9755 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/ac3enc.c
libavcodec/cabac.c
libavcodec/h264.c
libavcodec/snow.c

index 5aa415b6d63850efdb22753d1cdc1bc893052479..84bb7b02906138b36c7ac0d23c425e18aec06fd3 100644 (file)
@@ -1269,6 +1269,7 @@ static int AC3_encode_close(AVCodecContext *avctx)
 /*************************************************************************/
 /* TEST */
 
+#undef random
 #define FN (N/4)
 
 void fft_test(void)
index 2d51f6bcf0c2047d022e09bd5420b2a9f6d5fa57..7eb60b0ad236fa33047403c9580a4da2a7462a10 100644 (file)
@@ -179,6 +179,7 @@ void ff_init_cabac_states(CABACContext *c){
 }
 
 #if 0 //selftest
+#undef random
 #define SIZE 10240
 
 #include "avcodec.h"
index 515058116f12e950e4fb25686fcb9cbc6289ea37..c51496ae5b72e6469132d6cd5f6823fdc5103a62 100644 (file)
@@ -8101,6 +8101,7 @@ static inline void fill_mb_avail(H264Context *h){
 #endif
 
 #if 0 //selftest
+#undef random
 #define COUNT 8000
 #define SIZE (COUNT*40)
 int main(){
index b62f49ac15946e84e7225cca9f0fdde547b6fbe7..68d256606789f6fdc9e5e4917e0f507288743c32 100644 (file)
@@ -4552,6 +4552,7 @@ AVCodec snow_encoder = {
 #undef malloc
 #undef free
 #undef printf
+#undef random
 
 int main(){
     int width=256;