if (node->disc_watch)
l_dbus_remove_watch(dbus_get_bus(), node->disc_watch);
- if (node->path)
+ if (node->path) {
l_dbus_object_remove_interface(dbus_get_bus(), node->path,
MESH_NODE_INTERFACE);
+
+ l_dbus_object_remove_interface(dbus_get_bus(), node->path,
+ MESH_MANAGEMENT_INTERFACE);
+ }
+
l_free(node->path);
l_free(node);
{
l_queue_destroy(nodes, cleanup_node);
l_dbus_unregister_interface(dbus_get_bus(), MESH_NODE_INTERFACE);
+ l_dbus_unregister_interface(dbus_get_bus(), MESH_MANAGEMENT_INTERFACE);
}
bool node_is_provisioned(struct mesh_node *node)
"%s", uuid);
if (!l_dbus_object_add_interface(dbus_get_bus(), node->path,
- MESH_NODE_INTERFACE, node))
+ MESH_NODE_INTERFACE, node))
+ return false;
+
+ if (!l_dbus_object_add_interface(dbus_get_bus(), node->path,
+ MESH_MANAGEMENT_INTERFACE, node))
return false;
return true;
if (node->path) {
l_dbus_object_remove_interface(dbus_get_bus(), node->path,
MESH_NODE_INTERFACE);
+
+ l_dbus_object_remove_interface(dbus_get_bus(), node->path,
+ MESH_MANAGEMENT_INTERFACE);
l_free(node->app_path);
node->app_path = NULL;
}