projects
/
webpac
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6ed7c8a
)
fix mem_lookup with values which include characters which can be interpreted as regexes
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Wed, 24 May 2006 19:05:25 +0000
(19:05 +0000)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Wed, 24 May 2006 19:05:25 +0000
(19:05 +0000)
git-svn-id: file:///home/dpavlin/private/svn/webpac/trunk@742
13eb9ef6
-21d5-0310-b721-
a9d68796d827
filter/mem_lookup.pm
patch
|
blob
|
history
diff --git
a/filter/mem_lookup.pm
b/filter/mem_lookup.pm
index
d193356
..
f29e12c
100644
(file)
--- a/
filter/mem_lookup.pm
+++ b/
filter/mem_lookup.pm
@@
-32,7
+32,7
@@
sub mem_lookup {
if (/^(.+)\s=>\s(.+)$/) {
my ($k,$v) = ($1,$2);
# store in array if it doesn't exist
- if (! grep(/^
$v
$/, @{$main::cache->{mem_lookup}->{$k}})) {
+ if (! grep(/^
\Q$v\E
$/, @{$main::cache->{mem_lookup}->{$k}})) {
push @{$main::cache->{mem_lookup}->{$k}}, $v;
#print STDERR "## mem_lookup store: $k => $v [",join("|",@{$main::cache->{mem_lookup}->{$k}}),"]\n";
}