/pidgin/main: 29a7df06f410: Fix a warning for glib 2.36 and g_ty...

Tomasz Wasilczyk tomkiewicz at cpw.pidgin.im
Sat Apr 13 19:26:12 EDT 2013


Changeset: 29a7df06f410c4c41942965eadc0cef321b582e8
Author:	 Tomasz Wasilczyk <tomkiewicz at cpw.pidgin.im>
Date:	 2013-04-14 01:26 +0200
Branch:	 default
URL: https://hg.pidgin.im/pidgin/main/rev/29a7df06f410

Description:

Fix a warning for glib 2.36 and g_type_init

diffstat:

 libpurple/core.c       |   1 +
 libpurple/glibcompat.h |  12 +++++++++---
 2 files changed, 10 insertions(+), 3 deletions(-)

diffs (40 lines):

diff --git a/libpurple/core.c b/libpurple/core.c
--- a/libpurple/core.c
+++ b/libpurple/core.c
@@ -33,6 +33,7 @@
 #include "debug.h"
 #include "dnsquery.h"
 #include "ft.h"
+#include "glibcompat.h"
 #include "http.h"
 #include "idle.h"
 #include "imgstore.h"
diff --git a/libpurple/glibcompat.h b/libpurple/glibcompat.h
--- a/libpurple/glibcompat.h
+++ b/libpurple/glibcompat.h
@@ -25,6 +25,13 @@
  * Also, any public API should not depend on this file.
  */
 
+#if GLIB_CHECK_VERSION(2, 36, 0)
+
+#define g_type_init()
+
+#endif /* >= 2.36.0 */
+
+
 #if !GLIB_CHECK_VERSION(2, 32, 0)
 
 #define G_GNUC_BEGIN_IGNORE_DEPRECATIONS
@@ -53,9 +60,8 @@ static inline void g_slist_free_full(GSL
 	g_slist_free(list);
 }
 
-#endif /* 2.28.0 */
+#endif /* < 2.28.0 */
 
-#endif /* 2.32.0 */
+#endif /* < 2.32.0 */
 
 #endif /* _PIDGINGLIBCOMPAT_H_ */
-



More information about the Commits mailing list