[libpeas] Fix PEAS_DEBUG to work with glib's new G_MESSAGES_DEBUG
- From: Garrett Regier <gregier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libpeas] Fix PEAS_DEBUG to work with glib's new G_MESSAGES_DEBUG
- Date: Fri, 10 Feb 2012 18:51:58 +0000 (UTC)
commit a41cd38979057997686d2989d0aaab6b68c8bca8
Author: Garrett Regier <garrettregier gmail com>
Date: Fri Dec 9 15:07:57 2011 -0800
Fix PEAS_DEBUG to work with glib's new G_MESSAGES_DEBUG
libpeas/peas-debug.c | 21 +++++++++++++++++++++
1 files changed, 21 insertions(+), 0 deletions(-)
---
diff --git a/libpeas/peas-debug.c b/libpeas/peas-debug.c
index ec7616e..bec217a 100644
--- a/libpeas/peas-debug.c
+++ b/libpeas/peas-debug.c
@@ -44,4 +44,25 @@ peas_debug_init (void)
debug_log_handler,
NULL);
}
+ else
+ {
+ const gchar *g_messages_debug;
+
+ g_messages_debug = g_getenv ("G_MESSAGES_DEBUG");
+
+ if (g_messages_debug == NULL)
+ {
+ g_setenv ("G_MESSAGES_DEBUG", G_LOG_DOMAIN, TRUE);
+ }
+ else
+ {
+ gchar *new_g_messages_debug;
+
+ new_g_messages_debug = g_strconcat (g_messages_debug, " ",
+ G_LOG_DOMAIN, NULL);
+ g_setenv ("G_MESSAGES_DEBUG", new_g_messages_debug, TRUE);
+
+ g_free (new_g_messages_debug);
+ }
+ }
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]