mirror of
https://github.com/weechat/weechat.git
synced 2026-07-03 16:23:14 +02:00
SIGINT signal (Ctrl-C) intercepted, handler does nothing
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
WeeChat known bugs, 2003-11-17
|
||||
WeeChat known bugs, 2003-11-29
|
||||
|
||||
- ./configure does not check that Curses headers are installed
|
||||
- ./configure does not check that Gtk 2.0 libraries are installed
|
||||
@@ -9,7 +9,6 @@ WeeChat known bugs, 2003-11-17
|
||||
- too much nicks in the channel (> height of window) => display bug
|
||||
- some IRC commands are marked as 'unknown' when received
|
||||
(IRC protocol is under dev!)
|
||||
- intercept Ctrl-C (do not quit immediately if Ctrl-C pressed!)
|
||||
- too much opened channels => display bug
|
||||
- when kicked, channel is not prefixed by '(' and sufixed by ')'
|
||||
- when function key (non used by WeeChat) is pressed, prompt is deleted
|
||||
|
||||
@@ -50,6 +50,7 @@
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <time.h>
|
||||
#include <signal.h>
|
||||
|
||||
#include "weechat.h"
|
||||
#include "weeconfig.h"
|
||||
@@ -65,6 +66,15 @@ int quit_weechat; /* = 1 if quit request from user... why ? :'( */
|
||||
FILE *log_file; /* WeeChat log file (~/.weechat/weechat.log */
|
||||
|
||||
|
||||
/*
|
||||
* my_sigint: SIGINT handler, do nothing (just ignore this signal)
|
||||
*/
|
||||
|
||||
void
|
||||
my_sigint ()
|
||||
{
|
||||
}
|
||||
|
||||
/*
|
||||
* wee_log_printf: displays a message in WeeChat log (~/.weechat/weechat.log)
|
||||
*/
|
||||
@@ -237,6 +247,9 @@ main (int argc, char *argv[])
|
||||
textdomain (PACKAGE);
|
||||
#endif
|
||||
|
||||
/* ignore SIGINT signal (for example Ctrl-C) */
|
||||
signal (SIGINT, my_sigint);
|
||||
|
||||
/* pre-initiliaze interface */
|
||||
gui_pre_init (&argc, &argv);
|
||||
|
||||
|
||||
+1
-2
@@ -1,7 +1,7 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
WeeChat known bugs, 2003-11-17
|
||||
WeeChat known bugs, 2003-11-29
|
||||
|
||||
- ./configure does not check that Curses headers are installed
|
||||
- ./configure does not check that Gtk 2.0 libraries are installed
|
||||
@@ -9,7 +9,6 @@ WeeChat known bugs, 2003-11-17
|
||||
- too much nicks in the channel (> height of window) => display bug
|
||||
- some IRC commands are marked as 'unknown' when received
|
||||
(IRC protocol is under dev!)
|
||||
- intercept Ctrl-C (do not quit immediately if Ctrl-C pressed!)
|
||||
- too much opened channels => display bug
|
||||
- when kicked, channel is not prefixed by '(' and sufixed by ')'
|
||||
- when function key (non used by WeeChat) is pressed, prompt is deleted
|
||||
|
||||
@@ -50,6 +50,7 @@
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <time.h>
|
||||
#include <signal.h>
|
||||
|
||||
#include "weechat.h"
|
||||
#include "weeconfig.h"
|
||||
@@ -65,6 +66,15 @@ int quit_weechat; /* = 1 if quit request from user... why ? :'( */
|
||||
FILE *log_file; /* WeeChat log file (~/.weechat/weechat.log */
|
||||
|
||||
|
||||
/*
|
||||
* my_sigint: SIGINT handler, do nothing (just ignore this signal)
|
||||
*/
|
||||
|
||||
void
|
||||
my_sigint ()
|
||||
{
|
||||
}
|
||||
|
||||
/*
|
||||
* wee_log_printf: displays a message in WeeChat log (~/.weechat/weechat.log)
|
||||
*/
|
||||
@@ -237,6 +247,9 @@ main (int argc, char *argv[])
|
||||
textdomain (PACKAGE);
|
||||
#endif
|
||||
|
||||
/* ignore SIGINT signal (for example Ctrl-C) */
|
||||
signal (SIGINT, my_sigint);
|
||||
|
||||
/* pre-initiliaze interface */
|
||||
gui_pre_init (&argc, &argv);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user