/soc/2015/jgeboski/facebook: 480d3184752c: facebook: handle send...

James Geboski jgeboski at gmail.com
Tue Jun 23 17:16:15 EDT 2015


Changeset: 480d3184752ced695d0e4f5236282403068ee4d8
Author:	 James Geboski <jgeboski at gmail.com>
Date:	 2015-06-14 21:32 -0400
Branch:	 facebook
URL: https://hg.pidgin.im/soc/2015/jgeboski/facebook/rev/480d3184752c

Description:

facebook: handle sending failures

diffstat:

 libpurple/protocols/facebook/api.c |  6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diffs (16 lines):

diff --git a/libpurple/protocols/facebook/api.c b/libpurple/protocols/facebook/api.c
--- a/libpurple/protocols/facebook/api.c
+++ b/libpurple/protocols/facebook/api.c
@@ -337,6 +337,12 @@ fb_api_json_chk(FbApi *api, gconstpointe
 		return FALSE;
 	}
 
+	if (fb_json_node_chk_str(root, "$.failedSend.errorMessage", &msg)) {
+		fb_api_error(api, FB_API_ERROR_GENERAL, "%s", msg);
+		json_node_free(root);
+		return FALSE;
+	}
+
 	if (node != NULL) {
 		*node = root;
 	}



More information about the Commits mailing list