[Python-Dev] Adding support to curses library
A.M. Kuchling
amk at amk.ca
Wed Feb 25 16:34:17 CET 2009
On Wed, Feb 25, 2009 at 06:30:06AM -0800, Heracles wrote:
> is commented back in it does fail. I am not sure exactly how a debugger will
> help in this case since the color_set call goes directly to the ncurses
> library. If in fact that the issue is the ncurses library then it seems
> that there is no feasible solution until that library is fixed, in which
> case this patch is sort of useless.
...
> erg = color_set(color_pair_number, NULL); // Debating on forcing null
What is color_pair_number in the C code? If it's some incorrect value
(-1? 255?), maybe ncurses is indexing off an array and crashing.
This is why a debugger might help; you could run the test program
until the crash and then print out the values of the relevant
variables. e.g. is stdscr set to a non-NULL value? There might be a
debugging version of ncurses that will let you look at the variables
inside the ncurses code, which may make the problem clear.
--amk
More information about the Python-Dev
mailing list