From c7732655732824f25d1659f5ebb5d4c3538d32e8 Mon Sep 17 00:00:00 2001 From: Nick Ing-Simmons Date: Wed, 22 Jan 2003 09:06:23 +0000 Subject: [PATCH] Report layer name (without arg) on fail, and attempt to autoload layer name. (Fix for [perl #20460]). p4raw-id: //depot/perlio@18549 --- lib/open.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/open.pm b/lib/open.pm index d771fcb..c294093 100644 --- a/lib/open.pm +++ b/lib/open.pm @@ -95,8 +95,8 @@ sub import { my $target = $layer; # the layer name itself $target =~ s/^(\w+)\(.+\)$/$1/; # strip parameters - unless(PerlIO::Layer::->find($target)) { - warnings::warnif("layer", "Unknown PerlIO layer '$layer'"); + unless(PerlIO::Layer::->find($target,1)) { + warnings::warnif("layer", "Unknown PerlIO layer '$target'"); } } push(@val,":$layer"); -- 2.7.4