[Box Backup-dev] COMMIT r432 - box/chris/win32/vc2005-compile-fixes/lib/win32

boxbackup-dev at fluffy.co.uk boxbackup-dev at fluffy.co.uk
Sun Feb 12 00:29:45 GMT 2006


Author: chris
Date: 2006-02-12 00:29:42 +0000 (Sun, 12 Feb 2006)
New Revision: 432

Modified:
   box/chris/win32/vc2005-compile-fixes/lib/win32/emu.h
Log:
* emu.h
- Zero out struct tm to avoid random drift in and out of daylight savings
  (and other possible evil effects of random data in unset fields)


Modified: box/chris/win32/vc2005-compile-fixes/lib/win32/emu.h
===================================================================
--- box/chris/win32/vc2005-compile-fixes/lib/win32/emu.h	2006-02-12 00:17:28 UTC (rev 431)
+++ box/chris/win32/vc2005-compile-fixes/lib/win32/emu.h	2006-02-12 00:29:42 UTC (rev 432)
@@ -429,7 +429,8 @@
 	// Convert the last-write time to local time.
 	FileTimeToSystemTime(fileTime, &stUTC);
 	// SystemTimeToTzSpecificLocalTime(NULL, &stUTC, &stLocal);
-	
+
+	memset(&timeinfo, 0, sizeof(timeinfo));	
 	timeinfo.tm_sec = stUTC.wSecond;
 	timeinfo.tm_min = stUTC.wMinute;
 	timeinfo.tm_hour = stUTC.wHour;




More information about the Boxbackup-dev mailing list