]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - ncurses/base/lib_getstr.c
ncurses 5.6 - patch 20080816
[ncurses.git] / ncurses / base / lib_getstr.c
index 8ce18b34f1faef3a0f57458751b1f48f9123c4c5..b17df03d2a416bce2ccd98c8cda2c153ec92f990 100644 (file)
@@ -41,7 +41,7 @@
 #include <curses.priv.h>
 #include <term.h>
 
-MODULE_ID("$Id: lib_getstr.c,v 1.26 2008/05/31 22:05:15 tom Exp $")
+MODULE_ID("$Id: lib_getstr.c,v 1.27 2008/08/16 19:20:04 tom Exp $")
 
 /*
  * This wipes out the last character, no matter whether it was a tab, control
@@ -146,7 +146,7 @@ wgetnstr_events(WINDOW *win,
                   || (maxlen >= 0 && str - oldstr >= maxlen)) {
            beep();
        } else {
-           *str++ = ch;
+           *str++ = (char) ch;
            if (oldecho == TRUE) {
                int oldy = win->_cury;
                if (waddch(win, (chtype) ch) == ERR) {