diff options
author | Xin LI <delphij@FreeBSD.org> | 2017-04-25 03:42:16 +0000 |
---|---|---|
committer | Xin LI <delphij@FreeBSD.org> | 2017-04-25 03:42:16 +0000 |
commit | 9c83c2751d26fe2e059d6956f0398b56ed919a6a (patch) | |
tree | b75ed451f9f8336fb4958dbae186b6bd98aa65c0 /ttyin.c | |
parent | 1cabeb1f0c93e44ebc8a1d3a78100a962ac3f047 (diff) |
Diffstat (limited to 'ttyin.c')
-rw-r--r-- | ttyin.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -1,5 +1,5 @@ /* - * Copyright (C) 1984-2015 Mark Nudelman + * Copyright (C) 1984-2016 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. @@ -31,7 +31,7 @@ extern int utf_mode; * Open keyboard for input. */ public void -open_getchr(void) +open_getchr() { #if MSDOS_COMPILER==WIN32C /* Need this to let child processes inherit our console handle */ @@ -85,7 +85,7 @@ open_getchr(void) * Close the keyboard. */ public void -close_getchr(void) +close_getchr() { #if MSDOS_COMPILER==WIN32C SetConsoleMode((HANDLE)tty, console_mode); @@ -97,7 +97,7 @@ close_getchr(void) * Get a character from the keyboard. */ public int -getchr(void) +getchr() { char c; int result; @@ -135,8 +135,8 @@ getchr(void) #if 0 /* allow entering arbitrary hex chars for testing */ /* ctrl-A followed by two hex chars makes a byte */ { - int hex_in = 0; - int hex_value = 0; + static int hex_in = 0; + static int hex_value = 0; if (c == CONTROL('A')) { hex_in = 2; |