]> xenbits.xensource.com Git - libvirt.git/commit
lxc: Initializing IPv6 and IPv4 gateway to overwrite old settings.
authorJulio Faracco <jcfaracco@gmail.com>
Fri, 30 Nov 2018 12:43:36 +0000 (20:43 +0800)
committerJohn Ferlan <jferlan@redhat.com>
Tue, 11 Dec 2018 20:02:56 +0000 (15:02 -0500)
commit53762677a84c7bf124714d9e607da8c115084775
tree07d38b28bc738a5367fafa856a49aac897042c4b
parent34eca98522c1bd39e18f1eceee4f888dad173e5e
lxc: Initializing IPv6 and IPv4 gateway to overwrite old settings.

This commit fixes a bug when you have multiple network settings defined.
Basically, if you set an IPv6 or IPv4 gateway, it carries on next
network settings. It is happening because the data is not being
initialized when a new network type is defined. So, the old data still
persists into the pointer. Another way to initialized the data was
introduced using memset() to avoid missing attributes from the struct.

Signed-off-by: Julio Faracco <jcfaracco@gmail.com>
Reviewed-by: John Ferlan <jferlan@redhat.com>
src/lxc/lxc_native.c