From 0db3f478ea766bea293c125f7b9d9a891eceee52 Mon Sep 17 00:00:00 2001 From: William McBrine Date: Fri, 3 Nov 2006 13:36:47 +0000 Subject: [PATCH] Oops... need a refresh at the end of wgetnstr(). --- pdcurses/getstr.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pdcurses/getstr.c b/pdcurses/getstr.c index d2ad351d..f43b5550 100644 --- a/pdcurses/getstr.c +++ b/pdcurses/getstr.c @@ -13,7 +13,7 @@ #include -RCSID("$Id: getstr.c,v 1.36 2006/10/29 15:22:39 wmcbrine Exp $"); +RCSID("$Id: getstr.c,v 1.37 2006/11/03 13:36:47 wmcbrine Exp $"); /*man-start************************************************************** @@ -108,8 +108,6 @@ int wgetnstr(WINDOW *win, char *str, int n) immediately */ win->_nodelay = FALSE; /* don't return -1 */ - wrefresh(win); - while (!stop) { ch = wgetch(win); @@ -203,6 +201,8 @@ int wgetnstr(WINDOW *win, char *str, int n) } } + wrefresh(win); + *p = '\0'; SP->echo = oldecho; /* restore old settings */ @@ -300,8 +300,6 @@ int wgetn_wstr(WINDOW *win, wint_t *wstr, int n) immediately */ win->_nodelay = FALSE; /* don't return -1 */ - wrefresh(win); - while (!stop) { ch = wgetch(win); @@ -395,6 +393,8 @@ int wgetn_wstr(WINDOW *win, wint_t *wstr, int n) } } + wrefresh(win); + *p = '\0'; SP->echo = oldecho; /* restore old settings */