pidgin: 1a658bb7: conn->current_request can be NULL here.

datallah at pidgin.im datallah at pidgin.im
Mon Feb 2 11:15:39 EST 2009


-----------------------------------------------------------------
Revision: 1a658bb7a0436b518d65b9b95116915a5511a7d3
Ancestor: f3cf3ba10ebc911a27833496dcc4d4dca3de66c5
Author: datallah at pidgin.im
Date: 2009-02-02T16:13:11
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/1a658bb7a0436b518d65b9b95116915a5511a7d3

Modified files:
        libpurple/protocols/msn/soap.c

ChangeLog: 

conn->current_request can be NULL here.

-------------- next part --------------
============================================================
--- libpurple/protocols/msn/soap.c	6c780dac5c26608bb814d2a783acd4e510203fd5
+++ libpurple/protocols/msn/soap.c	a6c9a90fd13661ea0885013a22674f89da8657db
@@ -342,12 +342,14 @@ msn_soap_handle_body(MsnSoapConnection *
 	}
 
 	if (fault || body) {
-		MsnSoapRequest *request = conn->current_request;
-		conn->current_request = NULL;
-		request->cb(request->message, response,
-			request->cb_data);
+		if (conn->current_request) {
+			MsnSoapRequest *request = conn->current_request;
+			conn->current_request = NULL;
+			request->cb(request->message, response,
+				request->cb_data);
+			msn_soap_request_destroy(request, FALSE);
+		}
 		msn_soap_message_destroy(response);
-		msn_soap_request_destroy(request, FALSE);
 	}
 
 	return TRUE;


More information about the Commits mailing list