From: Jarkko Hietaniemi Date: Thu, 12 Jul 2001 17:08:15 +0000 (+0000) Subject: The problem seems to be in PerlIO::Layer::->find() not X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=738b23dc5cc678892953784996c86d67d1e166b7;p=p5sagit%2Fp5-mst-13.2.git The problem seems to be in PerlIO::Layer::->find() not accepting the ":encoding(blurflur)" arguments. p4raw-id: //depot/perl@11319 --- diff --git a/lib/open.pm b/lib/open.pm index 4c18c10..1456666 100644 --- a/lib/open.pm +++ b/lib/open.pm @@ -69,20 +69,18 @@ sub import { if ($locale_encoding =~ /^utf-?8$/i) { $layer = "utf8"; } else { - $layer = "encoding"; + $layer = "encoding($locale_encoding)"; } } unless(PerlIO::Layer::->find($layer)) { carp("Unknown discipline layer '$layer'"); } - if (defined $locale_encoding) { - $layer = "$layer($locale_encoding)"; - } push(@val,":$layer"); if ($layer =~ /^(crlf|raw)$/) { $^H{"open_$type"} = $layer; } } + # print "# type = $type, val = @val\n"; if ($type eq 'IN') { $in = join(' ',@val); }