develooper Front page | perl.perl5.porters | Postings from October 2003

Re: CGI::Cookie Warnings

Thread Previous | Thread Next
Nicholas Clark
October 22, 2003 13:10
Re: CGI::Cookie Warnings
Message ID:
On Tue, Oct 21, 2003 at 11:20:36PM -0700, David Wheeler wrote:
> Lincoln,
> Under some circumstances with Perl 5.8.1, I get this warning with 
> CGI::Cookie:
>   Ambiguous use of -time resolved as -&time() at 
> /usr/local/lib/perl5/5.8.1/CGI/ line 223.
> I believe that the attached simple patch addresses the issue. I've Cc'd 
> perl5-porters in the hope that the patch would also make it into the 
> core before the release of Perl 5.8.2.

[that bit makes sense to me - if an updated hits CPAN it can
get assimilated]

-  $self->{'max-age'} = CGI::Util::expire_calc($expires)-time if defined $expires;
+  $self->{'max-age'} = CGI::Util::expire_calc($expires) - time if defined $expires;

Eh? How on earth can whitespace be significant? :-(
Are you sure you were using perl and not some other language beginning with P?

Nicholas Clark

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About