/soc/2015/jgeboski/facebook: fb6acaae2788: facebook: fixed broke...

James Geboski jgeboski at gmail.com
Mon Jul 6 19:36:32 EDT 2015


Changeset: fb6acaae27882479196901e56751f93aabefe65e
Author:	 James Geboski <jgeboski at gmail.com>
Date:	 2015-07-06 19:36 -0400
Branch:	 facebook
URL: https://hg.pidgin.im/soc/2015/jgeboski/facebook/rev/fb6acaae2788

Description:

facebook: fixed broken logging from invalid level

diffstat:

 libpurple/protocols/facebook/util.c |  3 +++
 libpurple/protocols/facebook/util.h |  3 ++-
 2 files changed, 5 insertions(+), 1 deletions(-)

diffs (26 lines):

diff --git a/libpurple/protocols/facebook/util.c b/libpurple/protocols/facebook/util.c
--- a/libpurple/protocols/facebook/util.c
+++ b/libpurple/protocols/facebook/util.c
@@ -117,6 +117,9 @@ fb_util_vdebug(PurpleDebugLevel level, c
 		return;
 	}
 
+	/* Ensure all local flags are removed */
+	level &= ~FB_UTIL_DEBUG_FLAG_ALL;
+
 	str = g_strdup_vprintf(format, ap);
 	purple_debug(level, "facebook", "%s", str);
 	g_free(str);
diff --git a/libpurple/protocols/facebook/util.h b/libpurple/protocols/facebook/util.h
--- a/libpurple/protocols/facebook/util.h
+++ b/libpurple/protocols/facebook/util.h
@@ -41,7 +41,8 @@ typedef void (*FbUtilRequestBuddyFunc) (
 enum _FbUtilDebugFlags
 {
 	FB_UTIL_DEBUG_FLAG_UNSAFE  = 1 << 25,
-	FB_UTIL_DEBUG_FLAG_VERBOSE = 1 << 26
+	FB_UTIL_DEBUG_FLAG_VERBOSE = 1 << 26,
+	FB_UTIL_DEBUG_FLAG_ALL     = 3 << 25
 };
 
 enum _FbUtilError



More information about the Commits mailing list