]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - windows/wintime.c
wintime: add a precautionary memset to zero.
[PuTTY.git] / windows / wintime.c
index eebed9e5a4e4e5922a42d51f85be768d7df98d09..5fa3b0ded19e4f6d571b74c2d28169e653ad3061 100644 (file)
@@ -10,6 +10,8 @@ struct tm ltime(void)
     SYSTEMTIME st;
     struct tm tm;
 
+    memset(&tm, 0, sizeof(tm));        /* in case there are any other fields */
+
     GetLocalTime(&st);
     tm.tm_sec=st.wSecond;
     tm.tm_min=st.wMinute;