diff --git a/src/devices/ovs/nm-ovsdb.c b/src/devices/ovs/nm-ovsdb.c index 6c5d8be21e..5654dd6d3a 100644 --- a/src/devices/ovs/nm-ovsdb.c +++ b/src/devices/ovs/nm-ovsdb.c @@ -1020,8 +1020,12 @@ ovsdb_got_update (NMOvsdb *self, json_t *msg) } if (ovs) { + const char *s; + iter = json_object_iter (ovs); - priv->db_uuid = iter ? g_strdup (json_object_iter_key (iter)) : NULL; + s = json_object_iter_key (iter); + if (s) + nm_utils_strdup_reset (&priv->db_uuid, s); } /* Interfaces */