ffmpeg: dont call exit_program() from a signal hander
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 21 Mar 2014 14:45:03 +0000 (15:45 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 21 Mar 2014 16:09:56 +0000 (17:09 +0100)
This is unsafe and can deadlock amongth other things

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
ffmpeg.c

index e66cf2e..4b9209d 100644 (file)
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -328,7 +328,7 @@ sigterm_handler(int sig)
     received_nb_signals++;
     term_exit_sigsafe();
     if(received_nb_signals > 3)
-        exit_program(123);
+        exit(123);
 }
 
 void term_init(void)