mirror of
https://github.com/troglobit/editline.git
synced 2025-12-16 02:54:46 +08:00
Add support for disabling default SIGINT and EOF behavior.
This patch adds support for `--disable-eof` and `--disable-sigint` to the Editline configure script. With either of these two switches the `tty_special()` function bypasses the special TTY checks making it possible to bind Ctrl-C and Ctrl-D to custom callbacks. This can be useful if you want to emulate a Cisco style CLI rather than traditional UNIX. The user can of course also redefine the VINTR and VEOF special terminal control characters, but these configure script switches may be easier to use for some. Also, the CLI example has been updated to bind Ctrl-D, Ctrl-C and Ctrl-Z for testing purposes. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
@@ -12,6 +12,12 @@
|
||||
/* Define to enable the default completion handler. */
|
||||
#undef CONFIG_DEFAULT_COMPLETE
|
||||
|
||||
/* Define to enable EOF (Ctrl-C) key. */
|
||||
#undef CONFIG_EOF
|
||||
|
||||
/* Define to enable SIGINT (Ctrl-C) key. */
|
||||
#undef CONFIG_SIGINT
|
||||
|
||||
/* Define to enable SIGSTOP (Ctrl-Z) key. */
|
||||
#undef CONFIG_SIGSTOP
|
||||
|
||||
|
||||
Reference in New Issue
Block a user