Only validate the font face if it's non-null

Tue, 16 Dec 2008 04:08:38 +0000

author
Mark Doliner <markdoliner@pidgin.im>
date
Tue, 16 Dec 2008 04:08:38 +0000
changeset 25199
934b89b30715
parent 25198
dd8382881a45
child 25200
791738e352fc

Only validate the font face if it's non-null

libpurple/protocols/myspace/markup.c file | annotate | diff | comparison | revisions
--- a/libpurple/protocols/myspace/markup.c	Tue Dec 16 03:49:05 2008 +0000
+++ b/libpurple/protocols/myspace/markup.c	Tue Dec 16 04:08:38 2008 +0000
@@ -193,7 +193,7 @@
 	decor_str = xmlnode_get_attrib(root, "s");
 
 	/* Validate the font face, to avoid constructing invalid HTML later */
-	if (strchr(face, '\'') != NULL)
+	if (face != NULL && strchr(face, '\'') != NULL)
 		face = NULL;
 
 	height = height_str != NULL ? atol(height_str) : 12;

mercurial