diff options
Diffstat (limited to 'lib/terminal.c')
-rw-r--r-- | lib/terminal.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/terminal.c b/lib/terminal.c index df3e61d..ace1302 100644 --- a/lib/terminal.c +++ b/lib/terminal.c @@ -4,11 +4,12 @@ #include <termios.h> #include <string.h> #include "config.h" +#include "exceptions.h" FILE *input; struct termios initial_settings, new_settings; -void initterm() { +void initterm(void) { tcgetattr(fileno(input), &initial_settings); new_settings = initial_settings; new_settings.c_lflag &= ~ICANON; @@ -23,11 +24,11 @@ void initterm() { } -void clearterm() { +void clearterm(void) { tcsetattr(fileno(input), TCSANOW, &initial_settings); } -void openterm() { +void openterm(void) { if (!(input = fopen("/dev/tty", "r"))) { exception(1, _("could not open terminal")); } |