changeset 30482:783d736704b8

If removing a timeout and return FALSE in its handler isn't good, then returning TRUE probably isn't either.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Sat, 15 May 2010 08:02:08 +0000
parents 4463cd2aba2d
children 0662e5baada0
files libpurple/protocols/msn/directconn.c
diffstat 1 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/msn/directconn.c	Fri May 14 06:57:26 2010 +0000
+++ b/libpurple/protocols/msn/directconn.c	Sat May 15 08:02:08 2010 +0000
@@ -724,12 +724,14 @@
 
 	g_return_val_if_fail(dc != NULL, FALSE);
 
-	if (dc->progress)
+	if (dc->progress) {
 		dc->progress = FALSE;
-	else
+		return TRUE;
+	} else {
+		dc->timeout_handle = 0;
 		msn_dc_destroy(dc);
-
-	return TRUE;
+		return FALSE;
+	}
 }
 
 static void