exported-object: use _NMLOG2() macro for logging property-changed signal
This commit is contained in:
@@ -76,11 +76,20 @@ G_DEFINE_QUARK (NMExportedObjectClassInfo, nm_exported_object_class_info)
|
|||||||
#define _NMLOG_DOMAIN LOGD_CORE
|
#define _NMLOG_DOMAIN LOGD_CORE
|
||||||
|
|
||||||
#define _NMLOG(level, ...) \
|
#define _NMLOG(level, ...) \
|
||||||
nm_log (level, _NMLOG_DOMAIN, \
|
nm_log ((level), _NMLOG_DOMAIN, \
|
||||||
"%s[%p]: " _NM_UTILS_MACRO_FIRST (__VA_ARGS__), \
|
"%s[%p]: " _NM_UTILS_MACRO_FIRST (__VA_ARGS__), \
|
||||||
_NMLOG_PREFIX_NAME, (self) \
|
_NMLOG_PREFIX_NAME, (self) \
|
||||||
_NM_UTILS_MACRO_REST (__VA_ARGS__))
|
_NM_UTILS_MACRO_REST (__VA_ARGS__))
|
||||||
|
|
||||||
|
#define _NMLOG2_PREFIX_NAME "properties-changed"
|
||||||
|
#define _NMLOG2_DOMAIN LOGD_DBUS_PROPS
|
||||||
|
|
||||||
|
#define _NMLOG2(level, ...) \
|
||||||
|
nm_log ((level), _NMLOG2_DOMAIN, \
|
||||||
|
"%s[%p]: " _NM_UTILS_MACRO_FIRST (__VA_ARGS__), \
|
||||||
|
_NMLOG2_PREFIX_NAME, (self) \
|
||||||
|
_NM_UTILS_MACRO_REST (__VA_ARGS__))
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
/* "AddConnectionUnsaved" -> "handle-add-connection-unsaved" */
|
/* "AddConnectionUnsaved" -> "handle-add-connection-unsaved" */
|
||||||
@@ -830,11 +839,11 @@ idle_emit_properties_changed (gpointer self)
|
|||||||
variant = g_variant_ref_sink (g_variant_builder_end (¬ifies));
|
variant = g_variant_ref_sink (g_variant_builder_end (¬ifies));
|
||||||
|
|
||||||
|
|
||||||
if (nm_logging_enabled (LOGL_DEBUG, LOGD_DBUS_PROPS)) {
|
if (_LOG2D_ENABLED ()) {
|
||||||
gs_free char *notification = g_variant_print (variant, TRUE);
|
gs_free char *notification = g_variant_print (variant, TRUE);
|
||||||
|
|
||||||
nm_log_dbg (LOGD_DBUS_PROPS, "properties-changed[%p]: type %s, iface %s: %s",
|
_LOG2D ("type %s, iface %s: %s",
|
||||||
self, G_OBJECT_TYPE_NAME (self), G_OBJECT_TYPE_NAME (ifdata->interface),
|
G_OBJECT_TYPE_NAME (self), G_OBJECT_TYPE_NAME (ifdata->interface),
|
||||||
notification);
|
notification);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -877,8 +886,8 @@ nm_exported_object_notify (GObject *object, GParamSpec *pspec)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (!dbus_property_name) {
|
if (!dbus_property_name) {
|
||||||
nm_log_trace (LOGD_DBUS_PROPS, "properties-changed[%p]: ignoring notification for prop %s on type %s",
|
_LOG2T ("ignoring notification for prop %s on type %s",
|
||||||
self, pspec->name, G_OBJECT_TYPE_NAME (self));
|
pspec->name, G_OBJECT_TYPE_NAME (self));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user