Fix apparently exploitable race condition.
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 25 Mar 2011 01:24:32 +0000 (02:24 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 25 Mar 2011 01:24:32 +0000 (02:24 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavutil/log.c

index b3c9358..abf939d 100644 (file)
@@ -94,7 +94,8 @@ void av_log_default_callback(void* ptr, int level, const char* fmt, va_list vl)
 {
     static int print_prefix=1;
     static int count;
 {
     static int print_prefix=1;
     static int count;
-    static char line[1024], prev[1024];
+    static char prev[1024];
+    char line[1024];
     static int is_atty;
     AVClass* avc= ptr ? *(AVClass**)ptr : NULL;
     if(level>av_log_level)
     static int is_atty;
     AVClass* avc= ptr ? *(AVClass**)ptr : NULL;
     if(level>av_log_level)