Bug 1124882
Summary: | date fails to parse dates bigger than INT_MAX on 32bit arch | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Aleš Mareček <amarecek> |
Component: | coreutils | Assignee: | Kamil Dudka <kdudka> |
Status: | CLOSED WONTFIX | QA Contact: | qe-baseos-daemons |
Severity: | high | Docs Contact: | |
Priority: | medium | ||
Version: | 7.2 | CC: | hkario, kdudka, lmiksik, lpol, ovasik |
Target Milestone: | alpha | ||
Target Release: | 7.4 | ||
Hardware: | Unspecified | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2020-12-15 07:31:01 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Aleš Mareček
2014-07-30 14:32:46 UTC
The limitation here stems from the glibc and kernel representation of time_t which on 32 bit x86 at least is long, i.e. 31 bits. Now theoretically we could work around this by defining time64_t, mktime64(), localtime64() in gnulib, and parse_datetime() etc. would use those. Those functions in turn could call out to _time64() on windows, or otherwise on signed 32 bit time_t systems, handle at least the 32 bit wrap, thus handling dates until 2106. We could split the problem by only implementing mktime64() in gnulib, and thus supporting absolute times like in the above report without needing to worry about the kernel interface required for relative times. Though would it be worth doing that, when 64 bit supports this already? What's the use case for this exactly? Greetings, thank you for your quick response at first. We use this datetime functions in certificate testing what is broken on 32-bit archs. Timestamp is basic commonly used data type and shouldn't be faulty. Thanks and Regards! After evaluating this issue, there are no plans to address it further or fix it in an upcoming release. Therefore, it is being closed. If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened. |