summaryrefslogtreecommitdiffstats
path: root/contrib/perl5/lib/CGI/Cookie.pm
diff options
context:
space:
mode:
authormarkm <markm@FreeBSD.org>1999-05-02 14:33:17 +0000
committermarkm <markm@FreeBSD.org>1999-05-02 14:33:17 +0000
commit77644ee620b6a79cf8c538abaf7cd301a875528d (patch)
treeb4adabf341898a4378f4b7f8c7fb65f3f7c77769 /contrib/perl5/lib/CGI/Cookie.pm
parent4fcbc3669aa997848e15198cc9fb856287a6788c (diff)
downloadFreeBSD-src-77644ee620b6a79cf8c538abaf7cd301a875528d.zip
FreeBSD-src-77644ee620b6a79cf8c538abaf7cd301a875528d.tar.gz
Maintenance releace 3 of perl5.005. Includes support for threads.
Diffstat (limited to 'contrib/perl5/lib/CGI/Cookie.pm')
-rw-r--r--contrib/perl5/lib/CGI/Cookie.pm15
1 files changed, 8 insertions, 7 deletions
diff --git a/contrib/perl5/lib/CGI/Cookie.pm b/contrib/perl5/lib/CGI/Cookie.pm
index c32891a..204d67b 100644
--- a/contrib/perl5/lib/CGI/Cookie.pm
+++ b/contrib/perl5/lib/CGI/Cookie.pm
@@ -69,7 +69,9 @@ sub parse {
my($key,$value) = split("=");
my(@values) = map CGI::unescape($_),split('&',$value);
$key = CGI::unescape($key);
- $results{$key} = $self->new(-name=>$key,-value=>\@values);
+ # A bug in Netscape can cause several cookies with same name to
+ # appear. The FIRST one in HTTP_COOKIE is the most recent version.
+ $results{$key} ||= $self->new(-name=>$key,-value=>\@values);
}
return \%results unless wantarray;
return %results;
@@ -399,13 +401,12 @@ Get or set the cookie's expiration time.
=head1 AUTHOR INFORMATION
-be used and modified freely, but I do request that this copyright
-notice remain attached to the file. You may modify this module as you
-wish, but if you redistribute a modified version, please attach a note
-listing the modifications you have made.
+Copyright 1997-1998, Lincoln D. Stein. All rights reserved.
-Address bug reports and comments to:
-lstein@genome.wi.mit.edu
+This library is free software; you can redistribute it and/or modify
+it under the same terms as Perl itself.
+
+Address bug reports and comments to: lstein@cshl.org
=head1 BUGS
OpenPOWER on IntegriCloud