/cpw/tomkiewicz/gg11: 75f5a3c3cd67: Gadu-Gadu: more debug prints

Tomasz Wasilczyk tomkiewicz at cpw.pidgin.im
Thu Sep 20 13:54:49 EDT 2012


Changeset: 75f5a3c3cd67ee6c0cc4a7a35f79c7c44dfe95b4
Author:	 Tomasz Wasilczyk <tomkiewicz at cpw.pidgin.im>
Date:	 2012-09-20 19:54 +0200
Branch:	 default
URL: http://hg.pidgin.im/cpw/tomkiewicz/gg11/rev/75f5a3c3cd67

Description:

Gadu-Gadu: more debug prints

diffstat:

 libpurple/protocols/gg/image.c |  12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diffs (29 lines):

diff --git a/libpurple/protocols/gg/image.c b/libpurple/protocols/gg/image.c
--- a/libpurple/protocols/gg/image.c
+++ b/libpurple/protocols/gg/image.c
@@ -233,6 +233,13 @@ void ggp_image_send(PurpleConnection *gc
 	
 	sent_image = g_hash_table_lookup(sdata->sent_images, &id);
 	
+	if (sent_image == NULL && image_request->sender == ggp_str_to_uin(
+		purple_account_get_username(purple_connection_get_account(gc))))
+	{
+		purple_debug_misc("gg", "ggp_image_send: requested image "
+			"not found, but this may be another session request\n");
+		return;
+	}
 	if (sent_image == NULL)
 	{
 		purple_debug_warning("gg", "ggp_image_send: requested image "
@@ -310,6 +317,11 @@ void ggp_image_request(PurpleConnection 
 		if (gg_image_request(accdata->session, uin, size, crc) != 0)
 			purple_debug_error("gg", "ggp_image_request: failed\n");
 	}
+	else
+	{
+		purple_debug_info("gg", "ggp_image_request: "
+			"image %016llx already requested\n", id);
+	}
 	
 	listener = g_new0(ggp_image_requested_listener, 1);
 	listener->cb = cb;



More information about the Commits mailing list