]> xenbits.xensource.com Git - libvirt.git/commitdiff
util: support setting peer for virNetDevIPInfo addresses
authorLaine Stump <laine@laine.org>
Fri, 10 Jun 2016 16:37:37 +0000 (12:37 -0400)
committerLaine Stump <laine@laine.org>
Sat, 2 Jul 2016 01:13:31 +0000 (21:13 -0400)
This will apply to any IP address setting that uses
virNetDevIPInfoAddToDev() (which so far is only the guest-side of LXC
type='ethernet' interfaces).

(This patch had been pushed earlier in
commit cb20f989df393ec97ba65afb06089d0ab87af484, but was reverted in
commit cba06aea8d500d4ea7e2f40272be484027dd3e4a because it had been
accidentally pushed during the freeze for release 2.0.0)

src/util/virnetdevip.c

index ff0f2ddd3690d8cc9ad98852b7d745c1818b8bf7..d15976026c9950424c79956f1a2a43fd6c3c51ea 100644 (file)
@@ -920,7 +920,7 @@ virNetDevIPInfoAddToDev(const char *ifname,
             VIR_FREE(ipStr);
             goto cleanup;
         }
-        if (virNetDevIPAddrAdd(ifname, &ip->address, NULL, prefix) < 0)
+        if (virNetDevIPAddrAdd(ifname, &ip->address, &ip->peer, prefix) < 0)
             goto cleanup;
     }