OSDN Git Service

ffmpeg: Fix killing [Y/n] prompt with ctrl-c
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 16 Dec 2011 18:43:54 +0000 (19:43 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 16 Dec 2011 18:43:54 +0000 (19:43 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
ffmpeg.c

index aa90fe6..f64d739 100644 (file)
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -3302,6 +3302,7 @@ static void assert_file_overwrite(const char *filename)
                 fprintf(stderr,"File '%s' already exists. Overwrite ? [y/N] ", filename);
                 fflush(stderr);
                 term_exit();
+                signal(SIGINT, SIG_DFL);
                 if (!read_yesno()) {
                     av_log(0, AV_LOG_FATAL, "Not overwriting - exiting\n");
                     exit_program(1);