pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pkg/37173



The following reply was made to PR pkg/37173; it has been noted by GNATS.

From: "Valeriy E. Ushakov" <uwe%stderr.spb.ru@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: 
Subject: Re: pkg/37173
Date: Sat, 17 Nov 2007 02:56:27 +0300

 Suggested hack makes keypad keys (arrows &co) in tin work for me again.
 
 Our curses has no chance of working with tin, b/c tin does something
 in it's curses code that is not strictly legal.  In tcurses.c:ReadCh
 it does ungetch() on KEY_* values while our curses doesn't support
 that (as per SUS).  To quote the SUS (emphasis mine):
 
   The ungetch() function pushes the SINGLE-BYTE character ch onto the
   head of the input queue.
 
 and KEY_* values are from 0x100 up, i.e. not single-byte.  So later,
 when get_arrow_key calls getch() again it receives truncated value
 (KEY_* & 0xff) instead of the KEY_* value.
 
 -uwe
 



Home | Main Index | Thread Index | Old Index