From: Nicholas Clark Date: Sun, 4 Jul 2004 15:14:33 +0000 (+0000) Subject: /usr/bin/locale steadfastly delivers 8 bit output independent of X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d281a6ac99b66dc149fbd56ba67cd73e3e87afb9;p=p5sagit%2Fp5-mst-13.2.git /usr/bin/locale steadfastly delivers 8 bit output independent of LC_ALL. So when perl's expecting utf8, things don't quite work right. This has become visible since fix 22842 p4raw-id: //depot/perl@23028 --- diff --git a/lib/locale.t b/lib/locale.t index a294d2f..037e271 100644 --- a/lib/locale.t +++ b/lib/locale.t @@ -382,6 +382,10 @@ delete @ENV{qw(IFS CDPATH ENV BASH_ENV)}; if (-x "/usr/bin/locale" && open(LOCALES, "/usr/bin/locale -a 2>/dev/null|")) { while () { + # It seems that /usr/bin/locale steadfastly outputs 8 bit data, which + # ain't great when we're running this testPERL_UNICODE= so that utf8 + # locales will cause all IO hadles to default to (assume) utf8 + next unless utf8::valid($_); chomp; trylocale($_); }