changeset 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 7a2e45719bd0
children d321dd3e76da
files src/html.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
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;