diff options
author | Tom Gundersen <teg@jklm.no> | 2015-02-08 13:27:56 +0100 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2015-02-08 20:15:37 +0100 |
commit | 3175fcdec5d748e8db85a3e7fe1cb67f5f6a865d (patch) | |
tree | 69cb41bc019a32043bbb3fd3556f88aa5667b4fb /src/network/networkd-manager.c | |
parent | dbffab87f1504abc9f189dd253111693c99fbd9a (diff) |
networkd: add basic org.freedesktop.network1.Network interface
Diffstat (limited to 'src/network/networkd-manager.c')
-rw-r--r-- | src/network/networkd-manager.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/network/networkd-manager.c b/src/network/networkd-manager.c index e2c8a23e0f..4617f11867 100644 --- a/src/network/networkd-manager.c +++ b/src/network/networkd-manager.c @@ -174,6 +174,14 @@ int manager_connect_bus(Manager *m) { if (r < 0) return log_error_errno(r, "Failed to add link enumerator: %m"); + r = sd_bus_add_fallback_vtable(m->bus, NULL, "/org/freedesktop/network1/network", "org.freedesktop.network1.Network", network_vtable, network_object_find, m); + if (r < 0) + return log_error_errno(r, "Failed to add network object vtable: %m"); + + r = sd_bus_add_node_enumerator(m->bus, NULL, "/org/freedesktop/network1/network", network_node_enumerator, m); + if (r < 0) + return log_error_errno(r, "Failed to add network enumerator: %m"); + r = sd_bus_request_name(m->bus, "org.freedesktop.network1", 0); if (r < 0) return log_error_errno(r, "Failed to register name: %m"); |