X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=ncurses%2Fbase%2Flib_inchstr.c;h=aebb6d625d5c86705bae81061865203916c3966d;hp=884ea51fdb3bc8f0d4a21e825b464b6041b657d8;hb=b0b1980be11bba618d84beb8b30ac94e2c820602;hpb=3a0d9d27e0cf115ff9dcc6163c251bccaa62bd7d diff --git a/ncurses/base/lib_inchstr.c b/ncurses/base/lib_inchstr.c index 884ea51f..aebb6d62 100644 --- a/ncurses/base/lib_inchstr.c +++ b/ncurses/base/lib_inchstr.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998-2001,2009 Free Software Foundation, Inc. * + * Copyright (c) 1998-2009,2010 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,6 +29,7 @@ /**************************************************************************** * Author: Zeyd M. Ben-Halim 1992,1995 * * and: Eric S. Raymond * + * and: Thomas E. Dickey 1996-on * ****************************************************************************/ /* @@ -40,7 +41,7 @@ #include -MODULE_ID("$Id: lib_inchstr.c,v 1.11 2009/10/24 22:49:33 tom Exp $") +MODULE_ID("$Id: lib_inchstr.c,v 1.12 2010/12/20 01:37:41 tom Exp $") NCURSES_EXPORT(int) winchnstr(WINDOW *win, chtype *str, int n) @@ -55,7 +56,7 @@ winchnstr(WINDOW *win, chtype *str, int n) if (win) { for (; (n < 0 || (i < n)) && (win->_curx + i <= win->_maxx); i++) str[i] = - CharOf(win->_line[win->_cury].text[win->_curx + i]) | + (chtype) CharOf(win->_line[win->_cury].text[win->_curx + i]) | AttrOf(win->_line[win->_cury].text[win->_curx + i]); } str[i] = (chtype) 0;