X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Fredraw.c;h=9cb0de95a809a3e66845e559648668dacf8f51f7;hp=ce98259c321734baee31572131146f84f3571a5c;hb=ed3eb506e9a8e6ea871a2eb5818e19ba36f3f277;hpb=027ae42953e3186daed8f3882da73de48291b606 diff --git a/test/redraw.c b/test/redraw.c index ce98259c..9cb0de95 100644 --- a/test/redraw.c +++ b/test/redraw.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 2006 Free Software Foundation, Inc. * + * Copyright (c) 2006-2011,2012 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -26,7 +26,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: redraw.c,v 1.3 2006/11/04 23:20:27 tom Exp $ + * $Id: redraw.c,v 1.8 2012/12/08 20:46:02 tom Exp $ * * Demonstrate the redrawwin() and wredrawln() functions. * Thomas Dickey - 2006/11/4 @@ -65,6 +65,8 @@ test_redraw(WINDOW *win) int max_y, max_x; int beg_y, beg_x; + assert(win != 0); + scrollok(win, TRUE); keypad(win, TRUE); getmaxyx(win, max_y, max_x); @@ -111,7 +113,7 @@ test_redraw(WINDOW *win) * using mvcur(). It is ifdef'd for NCURSES, since X/Open does * not define the case where the old location is unknown. */ - system("date"); + IGNORE_RC(system("date")); mvcur(-1, -1, y, x); break; #endif @@ -148,7 +150,7 @@ test_redraw(WINDOW *win) if (ch > KEY_MIN) { waddstr(win, keyname(ch)); } else { - waddstr(win, unctrl(ch)); + waddstr(win, unctrl(UChar(ch))); } break; }