Re: strptime cannot parse date older than 1938
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com User-agent: Thunderbird 2.0.0.12 (Macintosh/20080213) The Y2038 bug is the unix stamp time range(1970-2038)? I know that and know what difference of long between 32 and 64. But I think strptime is not relative to this issue,since the struct tm store each date parts in a int or a char*,not like the unix timestamp store as a long. Well, on the Mac it only works if you compile for a 64bit architecture. btw:The "older" word cannot be used to compare tow date? If so,I am Sorry for my bad English.. -- Martin _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... Surf Chen wrote: The problem appears not to be the struct tm, but the conversion routine that perhaps somewhere internally uses the type time_t. And the codes works fine on my 32bit debian. You wrote "older than 1938" which is fine in English, but you did not mean 1938, you meant 2038. If in your program you write 1938 instead of 38 and %Y instead of %y, everything is OK. If you write 2038 and %Y, you get the same problem as for 38 and %y. This email sent to site_archiver@lists.apple.com
participants (1)
-
Martin Costabel