aboutsummaryrefslogtreecommitdiff
path: root/src/mm-log-object.c
diff options
context:
space:
mode:
authorDan Williams <dan@ioncontrol.co>2025-05-13 10:33:07 -0500
committerDan Williams <dan@ioncontrol.co>2025-05-23 18:46:32 -0500
commitb24615d8018c7cd78a744db0372c09c07543b763 (patch)
tree7402106180bc12a684156c3b285b1be534368485 /src/mm-log-object.c
parent42ead8826608f39491020863f4a4593918e3ae06 (diff)
log-object: don't construct log ID with NULL self_id
If the object has an owner ID already but doesn't yet have enough information to build its log ID, don't cache a less-than-useful log ID string for it. Signed-off-by: Dan Williams <dan@ioncontrol.co>
Diffstat (limited to 'src/mm-log-object.c')
-rw-r--r--src/mm-log-object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mm-log-object.c b/src/mm-log-object.c
index b5e390f1..64e4b407 100644
--- a/src/mm-log-object.c
+++ b/src/mm-log-object.c
@@ -63,7 +63,7 @@ mm_log_object_get_id (MMLogObject *self)
gchar *self_id;
self_id = MM_LOG_OBJECT_GET_IFACE (self)->build_id (self);
- if (priv->owner_id) {
+ if (self_id && priv->owner_id) {
priv->id = g_strdup_printf ("%s/%s", priv->owner_id, self_id);
g_free (self_id);
} else