After updating perl to latest 5.38.0. The Chinese characters are not displayed
properly if the LANG is zh_CN.UTF-8.
In the function Perl_init_i18nl10n() of perl's locale.c
Perl_init_i18nl10n()
{
......
uselocale(PL_C_locale_obj); /* zh_CN.UTF-8 returned not expected C if
setlocale(LC_CTYPE, NULL); */
......
}
and thus when perl try to emulate_setlocale_i() in line 5636 it found that the LC_CTYPE are both
the same in line 1176 and return back in line 1198. But the nl_langinfo(CODESET) is
"ANSI_X3.4‐1968" returned not "UTF-8".
--- rxvt-unicode-9.31.orig/src/rxvtperl.xs 2022-12-31 03:18:20.000000000
+0800
+++ rxvt-unicode-9.31/src/rxvtperl.xs 2023-07-07 11:03:55.307007386 +0800
@@ -399,7 +399,7 @@
{
if (!perl)
{
- rxvt_push_locale (""); // perl init destroys current locale
+ rxvt_push_locale ("C"); // perl init destroys current locale
{
perl_environ = rxvt_environ;
_______________________________________________
rxvt-unicode mailing list
[email protected]
http://lists.schmorp.de/mailman/listinfo/rxvt-unicode