diff src/html.c @ 4503:fdc4ac6d1db1

[gaim-migrate @ 4778] strip_html shouldn't segfault when passed NULL committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Sat, 01 Feb 2003 20:13:27 +0000
parents 7b0f6537da75
children d19872836812
line wrap: on
line diff
--- a/src/html.c	Sat Feb 01 19:26:45 2003 +0000
+++ b/src/html.c	Sat Feb 01 20:13:27 2003 +0000
@@ -50,6 +50,8 @@
 	int visible = 1;
 	gchar *text2 = g_strdup(text);
 
+	g_return_val_if_fail(text != NULL, NULL);
+
 	for (i = 0, j = 0; text2[i]; i++) {
 		if (text2[i] == '<') {
 			k = i + 1;