libpurple/protocols/yahoo/libymsg.c

changeset 29981
583d44798d66
parent 29980
c66778885cec
child 29985
cc4458135802
--- a/libpurple/protocols/yahoo/libymsg.c	Sat Apr 10 19:45:47 2010 +0000
+++ b/libpurple/protocols/yahoo/libymsg.c	Sat Apr 10 21:28:07 2010 +0000
@@ -1773,7 +1773,7 @@
 				tmp = &splits[i][14];
 				sem = strchr(tmp, ';');
 
-				if(tmp != NULL) {
+				if (sem != NULL) {
 					tmp2 = g_strndup(tmp, sem - tmp);
 					purple_debug_info("yahoo", "Got needed part of B cookie: %s\n",
 							tmp2 ? tmp2 : "(null)");
@@ -1783,6 +1783,7 @@
 		}
 	}
 
+	g_strfreev(splits);
 	return tmp2;
 }
 

mercurial