X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Fclip_printw.c;h=272da7b409c7f801e2f5919b5891106a6b5e39fb;hp=4a12ac8c513fd6fb7b8831e8cc2dd78915a75453;hb=77afe78361875f531dc2bf8d73f2e781c8e76176;hpb=dfaa1a3001fd447819f5edc2e523acc1a04f1440 diff --git a/test/clip_printw.c b/test/clip_printw.c index 4a12ac8c..272da7b4 100644 --- a/test/clip_printw.c +++ b/test/clip_printw.c @@ -26,7 +26,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: clip_printw.c,v 1.3 2009/07/17 09:28:52 tom Exp $ + * $Id: clip_printw.c,v 1.5 2009/10/24 21:02:55 tom Exp $ * * demonstrate how to use printw without wrapping. */ @@ -327,7 +327,7 @@ test_clipping(WINDOW *win) do { switch (st.ch) { case '.': /* change from current position */ - wattrset(win, st.attr | COLOR_PAIR(st.pair)); + (void) wattrset(win, st.attr | COLOR_PAIR(st.pair)); if (st.count > 0) { need = st.count + 1; sprintf(fmt, "%%c%%%ds%%c", st.count); @@ -337,7 +337,7 @@ test_clipping(WINDOW *win) } if ((buffer = typeMalloc(char, need)) != 0) { for (j = 0; j < need; ++j) { - buffer[j] = 'A' + (j % 26); + buffer[j] = (char) ('A' + (j % 26)); } buffer[need - 1] = '\0'; st.status = clip_wprintw(win, fmt, '[', buffer, ']'); @@ -367,6 +367,7 @@ main(int argc GCC_UNUSED, char *argv[]GCC_UNUSED) ExitProgram(EXIT_SUCCESS); } + #else int main(void)