changeset 30958:a467e55ec3c7

Move the call to flap_connection_schedule_destroy from oscar_chat_kill to oscar_chat_leave. This avoids having flap_connection_schedule_destroy called from purple_connerr, which itself is called by flap_connection_destroy_cb I'm hoping this change fixes #5927, the oscar crash when a flap connection is disconnected.
author Mark Doliner <mark@kingant.net>
date Mon, 22 Nov 2010 10:50:32 +0000
parents 3cf95447b26c
children 43af903bd816
files libpurple/protocols/oscar/oscar.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/oscar/oscar.c	Mon Nov 22 10:49:06 2010 +0000
+++ b/libpurple/protocols/oscar/oscar.c	Mon Nov 22 10:50:32 2010 +0000
@@ -283,7 +283,6 @@
 
 	/* Destroy the chat_connection */
 	od->oscar_chats = g_slist_remove(od->oscar_chats, cc);
-	flap_connection_schedule_destroy(cc->conn, OSCAR_DISCONNECT_DONE, NULL);
 	oscar_chat_destroy(cc);
 }
 
@@ -4451,6 +4450,7 @@
 			purple_conversation_get_name(conv));
 
 	cc = find_oscar_chat(gc, purple_conv_chat_get_id(PURPLE_CONV_CHAT(conv)));
+	flap_connection_schedule_destroy(cc->conn, OSCAR_DISCONNECT_DONE, NULL);
 	oscar_chat_kill(gc, cc);
 }