From 3c6d789c629f05e25179224f6900ad17d7d0aab2 Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Tue, 6 Aug 2013 16:29:09 -0500 Subject: logging: add log domain for D-Bus PropertiesChanged signal stuff Otherwise it really clutters up the CORE logging when debugging is enabled. --- src/logging/nm-logging.c | 5 +++-- src/logging/nm-logging.h | 1 + src/nm-properties-changed-signal.c | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/logging/nm-logging.c b/src/logging/nm-logging.c index c79e7d7069..05b021b087 100644 --- a/src/logging/nm-logging.c +++ b/src/logging/nm-logging.c @@ -49,9 +49,9 @@ nm_log_handler (const gchar *log_domain, LOGD_SUPPLICANT | LOGD_AGENTS | LOGD_SETTINGS | LOGD_SUSPEND | \ LOGD_CORE | LOGD_DEVICE | LOGD_OLPC_MESH | LOGD_WIMAX | \ LOGD_INFINIBAND | LOGD_FIREWALL | LOGD_ADSL | LOGD_BOND | \ - LOGD_VLAN | LOGD_BRIDGE) + LOGD_VLAN | LOGD_BRIDGE | LOGD_DBUS_PROPS) -#define LOGD_DEFAULT (LOGD_ALL & ~LOGD_WIFI_SCAN) +#define LOGD_DEFAULT (LOGD_ALL & ~(LOGD_WIFI_SCAN | LOGD_DBUS_PROPS)) static guint32 log_level = LOGL_INFO | LOGL_WARN | LOGL_ERR; static guint32 log_domains = LOGD_DEFAULT; @@ -102,6 +102,7 @@ static const LogDesc domain_descs[] = { { LOGD_BOND, "BOND" }, { LOGD_VLAN, "VLAN" }, { LOGD_BRIDGE, "BRIDGE" }, + { LOGD_DBUS_PROPS,"DBUS_PROPS" }, { 0, NULL } }; diff --git a/src/logging/nm-logging.h b/src/logging/nm-logging.h index c5df38f04a..147445bcee 100644 --- a/src/logging/nm-logging.h +++ b/src/logging/nm-logging.h @@ -58,6 +58,7 @@ enum { LOGD_BOND = 0x08000000, LOGD_VLAN = 0x10000000, LOGD_BRIDGE = 0x20000000, + LOGD_DBUS_PROPS = 0x40000000, }; #define LOGD_DHCP (LOGD_DHCP4 | LOGD_DHCP6) diff --git a/src/nm-properties-changed-signal.c b/src/nm-properties-changed-signal.c index e0ba7371b1..b61b87111b 100644 --- a/src/nm-properties-changed-signal.c +++ b/src/nm-properties-changed-signal.c @@ -106,7 +106,7 @@ properties_changed (gpointer data) GString *buf = g_string_new (NULL); g_hash_table_foreach (info->hash, add_to_string, buf); - nm_log_dbg (LOGD_CORE, "%s -> %s", G_OBJECT_TYPE_NAME (object), buf->str); + nm_log_dbg (LOGD_DBUS_PROPS, "%s -> %s", G_OBJECT_TYPE_NAME (object), buf->str); g_string_free (buf, TRUE); } @@ -146,7 +146,7 @@ notify (GObject *object, GParamSpec *pspec) break; } if (!dbus_property_name) { - nm_log_dbg (LOGD_CORE, "ignoring notification for prop %s on type %s", + nm_log_dbg (LOGD_DBUS_PROPS, "ignoring notification for prop %s on type %s", pspec->name, G_OBJECT_TYPE_NAME (object)); return; } -- cgit v1.2.1