Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: 2038 bug

by tachyon (Chancellor)
on Apr 11, 2003 at 05:19 UTC ( #249809=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    # get the difference between two epoch times and cope with 2038
    sub diff_time {
    ...
        require Math::BigInt;
        # blah
    }
    
  2. or download this
    my $zero_hour = 2**31 -1;
    print "Zero hour is $zero_hour\n";
    print scalar gmtime($zero_hour), "\n";
    print gmtime($zero_hour+1) ? "OK" . scalar gmtime($zero_hour+1) : 'Oh 
    +dear!';
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://249809]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (6)
As of 2014-12-27 04:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (176 votes), past polls