Change 16424 by ams@lustre on 2002/05/06 09:37:58
Subject: [PATCH] Term/Complete.pm: quote metachars
From: Brendan O'Dea <[EMAIL PROTECTED]>
Date: Mon, 6 May 2002 14:04:48 +1000
Message-Id: <[EMAIL PROTECTED]>
Affected files ...
.... //depot/perl/lib/Term/Complete.pm#13 edit
Differences ...
==== //depot/perl/lib/Term/Complete.pm#13 (text) ====
Index: perl/lib/Term/Complete.pm
--- perl/lib/Term/Complete.pm#12~12418~ Fri Oct 12 15:44:24 2001
+++ perl/lib/Term/Complete.pm Mon May 6 02:37:58 2002
@@ -116,7 +116,7 @@
CASE: {
# (TAB) attempt completion
$_ eq "\t" && do {
- @match = grep(/^$return/, @cmp_lst);
+ @match = grep(/^\Q$return/, @cmp_lst);
unless ($#match < 0) {
$l = length($test = shift(@match));
foreach $cmp (@match) {
@@ -133,7 +133,7 @@
# (^D) completion list
$_ eq $complete && do {
- print(join("\r\n", '', grep(/^$return/, @cmp_lst)), "\r\n");
+ print(join("\r\n", '', grep(/^\Q$return/, @cmp_lst)), "\r\n");
redo LOOP;
};
End of Patch.