Ticket #3114: fix broken build with NCurses.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2013-12-02 16:42:01 +04:00
parent a8ffc26817
commit d870aedad1
2 changed files with 3 additions and 2 deletions

View File

@ -1946,6 +1946,7 @@ int
tty_get_event (struct Gpm_Event *event, gboolean redo_event, gboolean block)
{
int c;
int flag = 0; /* Return value from select */
#ifdef HAVE_LIBGPM
static struct Gpm_Event ev; /* Mouse event */
#endif
@ -1978,7 +1979,6 @@ tty_get_event (struct Gpm_Event *event, gboolean redo_event, gboolean block)
while (pending_keys == NULL)
{
int nfd;
static int flag = 0; /* Return value from select */
fd_set select_set;
FD_ZERO (&select_set);

View File

@ -49,6 +49,7 @@
#include "tty-internal.h" /* mc_tty_normalize_from_utf8() */
#include "tty.h"
#include "color-internal.h"
#include "key.h"
#include "mouse.h"
#include "win.h"
@ -530,6 +531,7 @@ tty_print_anychar (int c)
if (mc_global.utf8_display || c > 255)
{
int res;
unsigned char str[UTF8_CHAR_LEN + 1];
res = g_unichar_to_utf8 (c, (char *) str);
if (res == 0)
@ -540,7 +542,6 @@ tty_print_anychar (int c)
}
else
{
unsigned char str[UTF8_CHAR_LEN + 1];
const char *s;
str[res] = '\0';