This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: glibc 2.1.92 tst-getdate failure on linuxppc
- To: Jack Howarth <howarth at fuse dot net>
- Subject: Re: glibc 2.1.92 tst-getdate failure on linuxppc
- From: Andreas Jaeger <aj at suse dot de>
- Date: 20 Aug 2000 12:28:06 +0200
- Cc: libc-alpha at sources dot redhat dot com
- References: <399F675F.922CE11C@fuse.net>
>>>>> Jack Howarth writes:
> Hello,
> I am wondering if we are the only platform seeing the following
> failure in
> make check on glibc 2.1.92? In build-ppc-linux/time/tst-getdate.out we
> see
> Failure for getdate ("16:30:46 2000-2-29"):
> struct tm is: 2000-1-29 16:30:46
> but should be: 2000-1-29 16:31:46
> No errors found.
> ...such that the struct tm is always 1 minute behind the actual time
> according to
> the test. Geoff sees this as well on linuxppc. I am curious if the same
> thing happens
> on any other platforms like i386. Thanks in advance for any hints or
> information.
The test case was wrong. I've committed the appended patch to fix
this.
Thanks,
Andreas
2000-08-20 Andreas Jaeger <aj@suse.de>
* time/tst-getdate.c (main): Increase error in case of wrong
conversion.
Fix typo in test case.
============================================================
Index: time/tst-getdate.c
--- time/tst-getdate.c 2000/03/03 19:45:50 1.1
+++ time/tst-getdate.c 2000/08/20 10:20:52
@@ -32,7 +32,7 @@
{
{"21:01:10 1999-1-31", 0, {10, 1, 21, 31, 0, 99, 0, 0, 0}},
{"21:01:10 1999-2-28", 0, {10, 1, 21, 28, 1, 99, 0, 0, 0}},
- {"16:30:46 2000-2-29", 0, {46, 31,16, 29, 1, 100, 0, 0, 0}}
+ {"16:30:46 2000-2-29", 0, {46, 30,16, 29, 1, 100, 0, 0, 0}}
};
void
@@ -103,8 +103,10 @@
tm->tm_year+1900, tm->tm_mon, tm->tm_mday,
tm->tm_hour, tm->tm_min, tm->tm_sec);
printf ("but should be: %d-%d-%d %d:%d:%d\n",
- tests[i].tm.tm_year+1900, tests[i].tm.tm_mon, tests[i].tm.tm_mday,
+ tests[i].tm.tm_year+1900, tests[i].tm.tm_mon,
+ tests[i].tm.tm_mday,
tests[i].tm.tm_hour, tests[i].tm.tm_min, tests[i].tm.tm_sec);
+ ++errors;
}
--
Andreas Jaeger
SuSE Labs aj@suse.de
private aj@arthur.inka.de
http://www.suse.de/~aj