bug in NIST-PCTS test suite (when testing mktime)

Todd C. Miller Todd.Miller at cs.colorado.edu
Wed Oct 30 00:19:14 UTC 1996


The following patch fixes things for PCTS, courtesy of
Thorsten Lockert <tholo at sigmasoft.com>.

 - todd

Index: localtime.c
===================================================================
RCS file: /cvs/src/lib/libc/time/localtime.c,v
retrieving revision 1.6
diff -u -r1.6 localtime.c
--- localtime.c	1996/09/05 12:28:23	1.6
+++ localtime.c	1996/10/30 00:14:32
@@ -1366,7 +1366,14 @@
 		dir = tmcomp(&mytm, &yourtm);
 		if (dir != 0) {
 			if (bits-- < 0)
+#ifdef PCTS
+			{
+				t += 2;
+				break;
+			}
+#else
 				return WRONG;
+#endif
 			if (bits < 0)
 				--t; /* may be needed if new t is minimal */
 			else if (dir > 0)



More information about the tz mailing list