diff options
| -rw-r--r-- | fml/lib/IO/Adapter.pm | 8 | ||||
| -rw-r--r-- | fml/lib/IO/Adapter/File.pm | 3 |
2 files changed, 8 insertions, 3 deletions
diff --git a/fml/lib/IO/Adapter.pm b/fml/lib/IO/Adapter.pm index 61bafed0..e58e2e87 100644 --- a/fml/lib/IO/Adapter.pm +++ b/fml/lib/IO/Adapter.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: Adapter.pm,v 1.27 2003/08/23 04:35:43 fukachan Exp $ +# $FML: Adapter.pm,v 1.28 2004/01/24 09:03:55 fukachan Exp $ # package IO::Adapter; @@ -410,6 +410,9 @@ sub find return $self->md_find($regexp, $args); } + # we may need quote for special address e.g. a+b@domain. + $regexp = quotemeta($regexp); + # What we want, key or key+value ? if (defined $args->{ want }) { if ($args->{ want } eq 'key' || @@ -422,7 +425,8 @@ sub find } # search regexp by reading the specified map. - my (@buf, $x); + my (@buf) = (); + my $x = ''; $self->open; my $fp = $want eq 'key' ? 'get_next_key' : 'getline'; diff --git a/fml/lib/IO/Adapter/File.pm b/fml/lib/IO/Adapter/File.pm index 587b413e..c286f443 100644 --- a/fml/lib/IO/Adapter/File.pm +++ b/fml/lib/IO/Adapter/File.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: File.pm,v 1.50 2003/11/27 04:26:09 fukachan Exp $ +# $FML: File.pm,v 1.51 2004/01/24 09:03:56 fukachan Exp $ # package IO::Adapter::File; @@ -444,6 +444,7 @@ sub delete my $wh = $self->{ _wh }; if (defined $fh) { + my $key = quotemeta($key); my $buf; FILE_IO: |
