changeset 31973:1e1b598c725e

Zero the struct tm used for purple_str_to_time(). This fixes parsing of date string without times, etc.
author Daniel Atallah <daniel.atallah@gmail.com>
date Mon, 02 May 2011 15:33:10 +0000
parents a5384cd9b332
children 6d3ba10e3f48
files libpurple/util.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/util.c	Mon May 02 14:01:43 2011 +0000
+++ b/libpurple/util.c	Mon May 02 15:33:10 2011 +0000
@@ -713,6 +713,8 @@
 
 	g_return_val_if_fail(timestamp != NULL, 0);
 
+	memset(&t, 0, sizeof(struct tm));
+
 	str = timestamp;
 
 	/* Strip leading whitespace */