From: He X <xw897002528@gmail.com>
To: musl@lists.openwall.com
Subject: Re: Re: a bug in bindtextdomain() and strip '.UTF-8'
Date: Mon, 13 Feb 2017 22:06:49 +0800 [thread overview]
Message-ID: <CAPG2z0-8NoD14Mm=ErQ2SO1A+HSV1McyFxSRUfB4X_nPiXB-eA@mail.gmail.com> (raw)
In-Reply-To: <20170213132816.GG1520@brightrain.aerifal.cx>
[-- Attachment #1: Type: text/plain, Size: 1185 bytes --]
no, it's on musl, i just tested it with my patches, with vim, stripping
will lead to unknown characters.
I mean, .mo files under zh_CN/ of vim is GBK set, while zh_CN/ of other
apps is UTF-8 set, that meas there may be other apps like vim, we should be
more cautious, add a check before map the .mo files, and fail non-UTF8 set
in setlocale.
Btw, _nl_msg_cat_cntr & _nl_domain_bindings will block apps compiling with
the native intl of musl, and after i added a dump for these two symbols,
gnu tar showed me segfaults, because he passed a zero msgid1 causing
__mo_lookup segfault, we should add a check in dcngettext to avoid it(if
(!msgid1) goto notrans;):
#2 0x00007ffff7d82a6f in dcngettext (domainname=0x6737a0 "tar",
msgid1=0x0, msgid2=0x0, n=1,
category=5) at src/locale/dcngettext.c:211
2017-02-13 21:28 GMT+08:00 Rich Felker <dalias@libc.org>:
> On Mon, Feb 13, 2017 at 04:01:31PM +0800, He X wrote:
> > New find, as you can see, zh_CN is different from zh_CN.UTF-8, it's GBK
> > codeset, we can't strip .UTF-8 easily, or we will get a lot of junk:
>
> That's on glibc; your "finding" is irrelevant to musl, where the
> encoding for all locales is UTF-8.
>
> Rich
>
[-- Attachment #2: Type: text/html, Size: 3048 bytes --]
next prev parent reply other threads:[~2017-02-13 14:06 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-20 11:25 He X
2017-01-29 4:52 ` He X
2017-01-29 13:39 ` Szabolcs Nagy
2017-01-29 14:07 ` Rich Felker
2017-01-29 14:48 ` He X
2017-01-29 15:55 ` Rich Felker
2017-01-29 16:14 ` He X
2017-01-29 16:33 ` Rich Felker
2017-02-08 10:13 ` He X
2017-02-08 14:31 ` Rich Felker
2017-02-09 9:49 ` He X
2017-02-11 2:36 ` Rich Felker
2017-02-11 6:00 ` He X
2017-02-11 23:59 ` Rich Felker
2017-02-12 2:34 ` Rich Felker
2017-02-12 6:56 ` He X
2017-02-12 7:11 ` He X
2017-02-13 17:08 ` Rich Felker
2017-02-13 8:01 ` He X
2017-02-13 13:28 ` Rich Felker
2017-02-13 14:06 ` He X [this message]
2017-02-13 17:12 ` Rich Felker
2017-03-04 8:02 ` He X
2017-03-17 19:27 ` Rich Felker
2017-03-17 19:37 ` Rich Felker
2017-03-18 7:34 ` He X
2017-03-18 12:28 ` Rich Felker
2017-03-18 13:50 ` He X
2017-02-13 14:12 ` He X
2017-02-13 17:13 ` Rich Felker
2017-01-29 16:37 ` Rich Felker
2017-01-30 0:37 ` He X
2017-01-30 14:17 ` He X
2017-01-29 16:40 ` Szabolcs Nagy
2017-01-29 16:49 ` Rich Felker
2017-01-30 12:36 ` He X
2017-01-30 13:05 ` Szabolcs Nagy
2017-01-30 1:32 ` He X
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAPG2z0-8NoD14Mm=ErQ2SO1A+HSV1McyFxSRUfB4X_nPiXB-eA@mail.gmail.com' \
--to=xw897002528@gmail.com \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).