develooper Front page | perl.perl5.porters | Postings from February 2018

[perl #132897] timegm should be called with 4-digit year

Thread Previous
From:
James E Keenan via RT
Date:
February 22, 2018 14:58
Subject:
[perl #132897] timegm should be called with 4-digit year
Message ID:
rt-4.0.24-29203-1519311515-991.132897-15-0@perl.org
On Thu, 22 Feb 2018 10:17:25 GMT, perlbugbmw@lsmod.de wrote:
> 
> This is a bug report for perl from perlbugbmw@lsmod.de,
> generated with the help of perlbug 1.39 running under perl 5.18.2.
> 
> 
> -----------------------------------------------------------------
> [Please describe your issue here]
> 
> timegm should be called with 4-digit year
> to avoid ambiguities in Time::Local with 2-digit years
> that cause a bug in 2020
> 
> note: while this is only documentation, I found that some people do
> RTFM
> and included this snippet in their module
> e.g. Parse-Win32Registry, HTTP-Cookies and HTTP-Message
> 
> please review/test/merge this fix:
> 
> --- perl-5.26.1.orig/pod/perlport.pod
> +++ perl-5.26.1/pod/perlport.pod
>  @@ -673 +673 @@
> -    my $offset = timegm(0, 0, 0, 1, 0, 70);
> +    my $offset = timegm(0, 0, 0, 1, 0, 1970);
> 

Pinging Dave Rolsky, upstream maintainer for Time::Local:

Dave, okay to make this change in 'perlport'?

Thank you very much.
Jim Keenan


-- 
James E Keenan (jkeenan@cpan.org)

---
via perlbug:  queue: perl5 status: new
https://rt.perl.org/Ticket/Display.html?id=132897

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About