reassign 356145 less
retitle 356145 less: Accented letters don't get bold
tags 356145 + patch
thanks
Hi,
This bug is actually in less. Here is a patch. Note: casting char into
integer extends the sign bit for >=128 characters, so you _need_ to cast
via (unsigned char).
Regards,
Samuel
diff -ur less-394/line.c less-394-mine/line.c
--- less-394/line.c 2005-12-03 21:20:32.000000000 +0100
+++ less-394-mine/line.c 2006-11-07 02:21:55.000000000 +0100
@@ -738,7 +738,7 @@
*/
public int
pappend(c, pos)
- char c;
+ unsigned char c;
POSITION pos;
{
int r;
@@ -883,7 +883,10 @@
*/
overstrike = utf_mode ? -1 : 0;
/* To be correct, this must be a base character. */
- prev_ch = get_wchar(linebuf + curr);
+ if (utf_mode)
+ prev_ch = get_wchar(linebuf + curr);
+ else
+ prev_ch = (unsigned char) linebuf[curr];
a = attr[curr];
if (ch == prev_ch)
{