changeset 27906:5f49b2dd8f9b

I just saw a crash where im was null here. No idea how to reproduce it
author Mark Doliner <mark@kingant.net>
date Thu, 13 Aug 2009 17:46:06 +0000
parents 55549f101140
children 9358464cdf6a c410e48a31c6
files libpurple/protocols/yahoo/libymsg.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/yahoo/libymsg.c	Thu Aug 13 15:56:13 2009 +0000
+++ b/libpurple/protocols/yahoo/libymsg.c	Thu Aug 13 17:46:06 2009 +0000
@@ -971,7 +971,7 @@
 
 	/* disconnect the peer if connected through p2p and sends wrong value for session id */
 	if( (pkt_type == YAHOO_PKT_TYPE_P2P) && (val_11 != yd->session_id) ) {
-		purple_debug_warning("yahoo","p2p: %s sent us message with wrong session id. Disconnecting p2p connection to peer\n", im->from);
+		purple_debug_warning("yahoo","p2p: %s sent us message with wrong session id. Disconnecting p2p connection to peer\n", im ? im->from : "(im was null)");
 		/* remove from p2p connection lists, also calls yahoo_p2p_disconnect_destroy_data */
 		g_hash_table_remove(yd->peers, im->from);
 		return;