Stories
Slash Boxes
Comments

SoylentNews is people

posted by Fnord666 on Friday February 02 2018, @09:18AM   Printer-friendly
from the I-don't-wget-it dept.

curl is a text-based utility and library for transferring data identified by their URLs. It is now year-2038 safe even on 32-bit systems. Daniel Stenberg, the orginal hacker of curl, has overseen a year-2038 fix for 32-bit systems. Without specific modifications, 32-bit systems cannot handle dates beyond 03:14:07 UTC on 19 January 2038. After that date, the time counter flips over and starts over again at zero, which would be the beginning of the UNIX epoch known as 00:00:00 UTC on 1 January 1970. Given the pervasiveness of 32-bit embedded systems and their long service lives, this is a serious problem and good (essential) to have fixed decades in advance. The OpenBSD project was the first major software project to take steps to avoid potential disaster from 32-bit time and awareness has since started to spread to other key software project such as curl.


Original Submission

 
This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
  • (Score: 2) by HiThere on Saturday February 03 2018, @01:43AM

    by HiThere (866) Subscriber Badge on Saturday February 03 2018, @01:43AM (#632300) Journal

    But for some systems that's using an extra 32 bits every time you invoke the time. Which is why I used two standards. The 64 bit int of nanoseconds would be a reasonable replacement for the 64 bit float I suggested as the second form, and you can argue quite reasonably that it shouldn't have a flexible epoch, but there also needs to be a more compact form.

    Actually, there need to be several standard forms, but they could all be based off of one of the other two bases. Sometimes what you need is a 16 bit time with a step size of 30 seconds. Usually memory isn't so tight that it really matters, but sometimes it does, and it's good to have well defined standards to drop into place. Float times have the advantage that different precisions of clock can each give all the precision they have available. etc. Of course you can do that with an int, too, but integers carry a false implication of total precision.

    --
    Javascript is what you use to allow unknown third parties to run software you have no idea about on your computer.
    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2