Date: Wed, 17 Sep 2008 07:00:05 GMT From: Edwin Groothuis <edwin@freebsd.org> To: freebsd-amd64@FreeBSD.org Subject: Re: amd64/109584: zdump(8) doesn't work Message-ID: <200809170700.m8H705Sk023583@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR amd64/109584; it has been noted by GNATS. From: Edwin Groothuis <edwin@freebsd.org> To: bug-followup@FreeBSD.org, dcrandall@simplestar.com Cc: Subject: Re: amd64/109584: zdump(8) doesn't work Date: Wed, 17 Sep 2008 16:53:17 +1000 Try Index: zdump.c =================================================================== --- zdump.c (revision 183065) +++ zdump.c (working copy) @@ -151,7 +151,9 @@ time_t hibit; struct tm tm; struct tm newtm; + int cpu32; + cpu32 = (sizeof(NULL) == 4); INITIALIZE(cuttime); #if HAVE_GETTEXT - 0 (void) setlocale(LC_MESSAGES, ""); @@ -222,9 +224,16 @@ /* ** Get lowest value of t. */ - t = hibit; - if (t > 0) /* time_t is unsigned */ - t = 0; + if (cpu32) { + t = hibit; + if (t > 0) /* time_t is unsigned */ + t = 0; + } else { + t = -2209024800; /* 1 January 1900 00:00:00 */ + cuttime = 4000000000; + cutoff = "2099"; + } + show(argv[i], t, TRUE); t += SECSPERHOUR * HOURSPERDAY; show(argv[i], t, TRUE); It won't resolve the issue, only mask it for now. The problem is that the time after 2037 is still not shown . -- Edwin Groothuis edwin@freebsd.org http://www.mavetju.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200809170700.m8H705Sk023583>