xref: /openbsd-src/gnu/usr.bin/perl/t/op/time_loop.t (revision b39c515898423c8d899e35282f4b395f7cad3298)
1*b39c5158Smillert#!perl -w
2*b39c5158Smillert
3*b39c5158Smillert# d95a2ea538e6c332f36c34ca45b78d6ad93c3a1f allowed times greater than
4*b39c5158Smillert# 2**63 to be handed to gm/localtime() which caused an internal overflow
5*b39c5158Smillert# and an excessively long loop.  Test this does not happen.
6*b39c5158Smillert
7*b39c5158Smillertuse strict;
8*b39c5158Smillert
9*b39c5158SmillertBEGIN { require './test.pl'; }
10*b39c5158Smillert
11*b39c5158Smillertplan tests => 2;
12*b39c5158Smillertwatchdog(2);
13*b39c5158Smillert
14*b39c5158Smillertlocal $SIG{__WARN__} = sub {};
15*b39c5158Smillertis gmtime(2**69),    undef;
16*b39c5158Smillertis localtime(2**69), undef;
17