GNU bug report logs - #32236
df header corrupted with LANG=zh_TW.UTF-8 on macOS

Previous Next

Package: coreutils;

Reported by: Chih-Hsuan Yen <yan12125 <at> gmail.com>

Date: Sat, 21 Jul 2018 16:10:02 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Chih-Hsuan Yen <yan12125 <at> gmail.com>
To: 32236 <at> debbugs.gnu.org
Subject: bug#32236: df header corrupted with LANG=zh_TW.UTF-8 on macOS
Date: Sat, 21 Jul 2018 22:20:04 +0800
Hi coreutils developers,

I'm using coreutils on macOS High Sierra (10.13). I noticed that with
`LANG=zh_TW.UTF-8`, `df` output is corrupted.

�?�?系統 容�?? 已�?� �?��?� 已�?�% �??�?�?
/dev/disk1s1    234G  151G    81G    65% /
/dev/disk1s4    234G  2.1G    81G     3% /private/var/vm

(I'm not sure if other mail agents can display those characters
correctly or not. See my blog post [1] for the exact output.)

Seems it's similar to bug#25630 [2], which is not resolved. I guess
the reason of my issue is that iscntrl() is broken on macOS High
Sierra, so in hide_problematic_chars(), some bytes in the Chinese
header is replaced with a question mark. I managed to patch coreutils
[3] to make `df` work. Could you have a look? Thanks!

Best,

Chih-Hsuan Yen

[1] https://blog.chyen.cc/posts/2018/06/23/mac-df-chinese.html
[2] http://lists.gnu.org/archive/html/bug-coreutils/2017-02/msg00008.html
[3] https://github.com/yan12125/macports-ports/blob/fix-coreutils-df-chinese/sysutils/coreutils/files/patch-df.diff




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

Previous Next


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