X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Ftestaddch.c;h=d0c36d434b66d2d3710bfcf59f92e325489267f9;hp=7a909e28ab95f89a1ae9c23d0f52535d26696286;hb=6af42291adceeb1bd8caab41e16762ec6d96529c;hpb=c8e187fc9682a3c5cfaebc480fc98d8585f6caf6 diff --git a/test/testaddch.c b/test/testaddch.c index 7a909e28..d0c36d43 100644 --- a/test/testaddch.c +++ b/test/testaddch.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc. * + * Copyright (c) 1998-2009,2011 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 * @@ -29,7 +29,7 @@ * This is an example written by Alexander V. Lukyanov , * to demonstrate an inconsistency between ncurses and SVr4 curses. * - * $Id: testaddch.c,v 1.7 2009/08/29 19:02:25 tom Exp $ + * $Id: testaddch.c,v 1.8 2011/04/23 20:13:12 tom Exp $ */ #include @@ -63,7 +63,7 @@ main( for (i = 0; i < 8; i++) { back = (i & 1) ? A_BOLD | 'B' : ' '; set = (i & 2) ? A_REVERSE : 0; - attr = (i & 4) ? COLOR_PAIR(4) : 0; + attr = (chtype) ((i & 4) ? COLOR_PAIR(4) : 0); bkgdset(back); (void) attrset(set); @@ -74,7 +74,7 @@ main( for (i = 0; i < 8; i++) { back = (i & 1) ? A_BOLD | 'B' | COLOR_PAIR(1) : ' '; set = (i & 2) ? A_REVERSE | COLOR_PAIR(2) : 0; - attr = (i & 4) ? COLOR_PAIR(4) : 0; + attr = (chtype) ((i & 4) ? COLOR_PAIR(4) : 0); bkgdset(back); (void) attrset(set);