changeset 18765:9cec393c3a21

Fix #2349 (null pointer deref in log_reader plugin).
author Daniel Atallah <daniel.atallah@gmail.com>
date Wed, 01 Aug 2007 02:13:16 +0000
parents 542af7636303
children 69556cf286f8
files libpurple/plugins/log_reader.c
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/plugins/log_reader.c	Wed Aug 01 01:34:53 2007 +0000
+++ b/libpurple/plugins/log_reader.c	Wed Aug 01 02:13:16 2007 +0000
@@ -874,7 +874,8 @@
 	GString *text = NULL;
 	xmlnode *message;
 
-	*flags = PURPLE_LOG_READ_NO_NEWLINE;
+	if (flags != NULL)
+		*flags = PURPLE_LOG_READ_NO_NEWLINE;
 	g_return_val_if_fail(log != NULL, g_strdup(""));
 
 	data = log->logger_data;