[systemd-commits] src/nspawn TODO

Tom Gundersen tomegun at kemper.freedesktop.org
Thu Aug 28 03:19:10 PDT 2014


 TODO                |    2 --
 src/nspawn/nspawn.c |    2 +-
 2 files changed, 1 insertion(+), 3 deletions(-)

New commits:
commit 3125b3ef5db70d45882c7d6f617705802c5f939e
Author: Tom Gundersen <teg at jklm.no>
Date:   Thu Aug 28 12:15:51 2014 +0200

    nspawn: fix --network-interface
    
    Use SETLINK when modifying an existing link.

diff --git a/TODO b/TODO
index bc81a70..a00c13d 100644
--- a/TODO
+++ b/TODO
@@ -24,8 +24,6 @@ External:
 
 Features:
 
-* nspawn --network-interface= doesn't work...
-
 * dbus: add new message hdr field for allowing interactive auth, write spec for it. update dbus spec to mandate that unknown flags *must* be ignored...
 
 * maybe introduce AssertXYZ= similar to ConditionXYZ= that causes a unit to fail (instead of skipping it) if some condition is not true...
diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c
index 56d9cc6..5af89c9 100644
--- a/src/nspawn/nspawn.c
+++ b/src/nspawn/nspawn.c
@@ -1886,7 +1886,7 @@ static int move_network_interfaces(pid_t pid) {
                 if (ifi < 0)
                         return ifi;
 
-                r = sd_rtnl_message_new_link(rtnl, &m, RTM_NEWLINK, ifi);
+                r = sd_rtnl_message_new_link(rtnl, &m, RTM_SETLINK, ifi);
                 if (r < 0) {
                         log_error("Failed to allocate netlink message: %s", strerror(-r));
                         return r;



More information about the systemd-commits mailing list