[BusyBox-cvs] busybox/coreutils date.c,1.40,1.41

Manuel Novoa III mjn3 at busybox.net
Wed Jul 23 23:24:34 UTC 2003


Update of /var/cvs/busybox/coreutils
In directory winder:/tmp/cvs-serv14258

Modified Files:
	date.c 
Log Message:
Set the tm_isdst flag to -1 before calling mktime().  Otherwise, the current
timezone setting is used for the new date.


Index: date.c
===================================================================
RCS file: /var/cvs/busybox/coreutils/date.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- date.c	20 Jun 2003 09:01:52 -0000	1.40
+++ date.c	23 Jul 2003 23:24:31 -0000	1.41
@@ -209,6 +209,7 @@
 		}
 
 		/* Correct any day of week and day of year etc. fields */
+		tm_time.tm_isdst = -1;	/* Be sure to recheck dst. */
 		tm = mktime(&tm_time);
 		if (tm < 0) {
 			bb_error_msg_and_die(bb_msg_invalid_date, date_str);




More information about the busybox-cvs mailing list