File config_ipv6-run-inet_pton-on-the-addr-value-without-.patch of Package lxc.openSUSE_13.1_Update
From: Serge Hallyn <serge.hallyn@ubuntu.com>
Date: Fri, 23 Aug 2013 12:45:15 -0500
Subject: config_ipv6: run inet_pton on the addr value without mask
Patch-mainline: no
References: bnc#851760
otherwise a "$addr/$mask" results in failure.
Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
---
src/lxc/confile.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: lxc-0.9.0/src/lxc/confile.c
===================================================================
--- lxc-0.9.0.orig/src/lxc/confile.c
+++ lxc-0.9.0/src/lxc/confile.c
@@ -745,8 +745,8 @@ static int config_network_ipv6(const cha
inet6dev->prefix = atoi(netmask);
}
- if (!inet_pton(AF_INET6, value, &inet6dev->addr)) {
- SYSERROR("invalid ipv6 address: %s", value);
+ if (!inet_pton(AF_INET6, valdup, &inet6dev->addr)) {
+ SYSERROR("invalid ipv6 address: %s", valdup);
free(valdup);
return -1;
}