GNU bug report logs - #33053
scm_i_mirror_backslashes assumes ASCII-compatible locale encoding

Previous Next

Package: guile;

Reported by: Mark H Weaver <mhw <at> netris.org>

Date: Mon, 15 Oct 2018 20:47:01 UTC

Severity: normal

Tags: notabug

Done: Mark H Weaver <mhw <at> netris.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Mark H Weaver <mhw <at> netris.org>
To: 33053 <at> debbugs.gnu.org
Subject: bug#33053: scm_i_mirror_backslashes assumes ASCII-compatible locale encoding
Date: Mon, 15 Oct 2018 19:06:53 -0400
Mark H Weaver <mhw <at> netris.org> writes:

> The 'scm_i_mirror_backslashes' in load.c operates on C strings in the
> locale encoding, and assumes that the locale encoding is ASCII
> compatible.  In the Shift_JIS encoding, used in the "JP_jp.sjis" locale,
> backslash '\' is mapped to a multibyte character, and the Yen sign '¥'
> is represented using code 0x5C, the same code as backslash '\' in ASCII.
>
> As a result, users of the "JP_jp.sjis" locale will have Yen signs '¥' in
> their file names converted into slashes by this function.

I miswrote the locale name above.  The locale name is "ja_JP.sjis".

      Mark




This bug report was last modified 6 years and 218 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.