summaryrefslogtreecommitdiff
path: root/lib/Term
diff options
context:
space:
mode:
authorNorton T. Allen <allen@huarp.harvard.edu>2002-01-02 09:22:09 -0500
committerAbhijit Menon-Sen <ams@wiw.org>2002-01-02 18:16:12 +0000
commit96af66be42b7864817b8cbb1e321096e1a058501 (patch)
treef486ca54f11840be28c6052bb221eb5fc305eb83 /lib/Term
parent35b807ef3d5d20fcb1e7afd29ca7ede8931d5a85 (diff)
downloadperl-96af66be42b7864817b8cbb1e321096e1a058501.tar.gz
PATCH: lib/Term/Cap.pm
Message-Id: <200201021922.OAA18505@bottesini.harvard.edu> p4raw-id: //depot/perl@14024
Diffstat (limited to 'lib/Term')
-rw-r--r--lib/Term/Cap.pm8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/Term/Cap.pm b/lib/Term/Cap.pm
index 0e34d7a3da..8cf14c97c1 100644
--- a/lib/Term/Cap.pm
+++ b/lib/Term/Cap.pm
@@ -213,11 +213,15 @@ sub Tgetent { ## public -- static method
$entry = $VMS_TERMCAP;
}
else {
+ if ( grep { -x "$_/infocmp" } split /:/, $ENV{PATH} ) {
eval
{
- $entry = `infocmp -C 2>/dev/null`
- if grep { -x "$_/infocmp" } split /:/, $ENV{PATH};
+ $foo = `infocmp -C 2>/dev/null`;
+ if (($foo !~ m:^/:s) && ($foo =~ m/(^|\|)${termpat}[:|]/s)) {
+ $entry = $foo;
+ }
}
+ }
}
}