diff options
author | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-01-08 21:40:44 +0000 |
---|---|---|
committer | reimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-01-08 21:40:44 +0000 |
commit | 876b028289c88748dd9c3e54d4a83e29a1c9e13b (patch) | |
tree | c495b6f191c2a13ccce8bb7d3ad1fc6c1532c928 /mplayer.c | |
parent | 87340de57f001076cd8bac0f7b638cc667bf17c3 (diff) | |
download | mpv-876b028289c88748dd9c3e54d4a83e29a1c9e13b.tar.bz2 mpv-876b028289c88748dd9c3e54d4a83e29a1c9e13b.tar.xz |
Do not use exit_player in the signal handler, this code just can not
be called from a signal handler.
Instead only make the input system generate quit commands for the first
CTRL+C and otherwise do getch2_disable and exit.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25651 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'mplayer.c')
-rw-r--r-- | mplayer.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -764,7 +764,8 @@ static void exit_sighandler(int x){ case SIGQUIT: case SIGTERM: case SIGKILL: - break; // killed from keyboard (^C) or killed [-9] + async_quit_request = 1; + return; // killed from keyboard (^C) or killed [-9] case SIGILL: #ifdef RUNTIME_CPUDETECT mp_msg(MSGT_CPLAYER,MSGL_FATAL,MSGTR_Exit_SIGILL_RTCpuSel); @@ -798,7 +799,8 @@ static void exit_sighandler(int x){ } #endif } - exit_player(NULL); + getch2_disable(); + exit(1); } extern void mp_input_register_options(m_config_t* cfg); |