From: Mischa POSLAWSKY Date: Sat, 6 Sep 2008 23:45:39 +0000 (+0000) Subject: digraphs: fix latin1 glyph conversion X-Git-Tag: v1.2~66 X-Git-Url: http://git.shiar.nl/sheet.git/commitdiff_plain/e84402a9c62d8b57f9fd78a81d639692108a46e3 digraphs: fix latin1 glyph conversion Under FastCGI, latin1 glyphs were displayed with their internal string representation, because the output buffer was not :utf8 (FCGI flaw). At least that's what I gather. Force to Unicode beforehand so it's shown correctly. --- diff --git a/digraphs.plp b/digraphs.plp index 9a20f58..9f0b370 100644 --- a/digraphs.plp +++ b/digraphs.plp @@ -69,11 +69,13 @@ for my $c1 (@chars) { next; } my $chr = $di->{$mnem}; + my $glyph = chr $chr; + utf8::upgrade($glyph); # prevent latin1 output my @class = 'any'; printf '%s', - join(' ', @class), quote($mnem), quote(chr $chr); + join(' ', @class), quote($mnem), quote($glyph); } print "\n"; }