pkgsrc-Bugs archive

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

pkg/60844: www/lynx with NetBSD curses fails to display utf-8



>Number:         60844
>Category:       pkg
>Synopsis:       www/lynx with NetBSD curses fails to display utf-8
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Oct 03 11:20:00 +0000 2026
>Originator:     Valery Ushakov
>Release:        pkgsrc-2026Q3
>Organization:
>Environment:
NetBSD omena 11.0 NetBSD 11.0 (GENERIC) #0: Thu Jul 30 15:23:12 UTC 2026  mkrepro%mkrepro.NetBSD.org@localhost:/usr/src/sys/arch/amd64/compile/GENERIC amd64

>Description:
I use lynx with utf-8 display charset (and utf-8 locale) and raw mode
OFF on NetBSD with netbsd curses.  When I open www.netbsd.org instead
of angle quotes, like:

  » Learn more

I get

  �» Learn more

I.e. the two bytes of utf-8 representation of the quote are displayed
as two characters, not one.

If I open an HTML with cyrillic, I get all the characters split this
way:

  ��¸�²�µ�

instead of

  Ð?Ñ?ивеÑ?

>How-To-Repeat:
Set RAW to OFF, set display charset to UTF-8, open www.netbsd.org.
In a typical 80x24 terminal you'll need to page down once.

>Fix:
I tracked it down to LYwaddnstr (in LYCurses.c) calling

  waddch(w, UCH(src[inx]));

in a loop, which obviously rips the utf-8 apart.

I'll attach a patch in a follow-up e-mail.




Home | Main Index | Thread Index | Old Index