[Olsr-dev] [PATCH v1 17/19] gateway: the gateway to set must either be an IPv4 or IPv6 gateway or both
Ferry Huberts
(spam-protected)
Thu Aug 23 15:12:41 CEST 2012
From: Ferry Huberts <(spam-protected)>
Signed-off-by: Ferry Huberts <(spam-protected)>
---
src/gateway.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/gateway.c b/src/gateway.c
index 1e9b729..7576ed2 100644
--- a/src/gateway.c
+++ b/src/gateway.c
@@ -484,6 +484,9 @@ bool olsr_set_inet_gateway(union olsr_ip_addr *originator, bool ipv4, bool ipv6)
ipv4 = ipv4 && (olsr_cnf->ip_version == AF_INET || olsr_cnf->use_niit);
ipv6 = ipv6 && (olsr_cnf->ip_version == AF_INET6);
+ if (!ipv4 && !ipv6) {
+ return true;
+ }
entry = node2gateway(avl_find(&gateway_tree, originator));
if (!entry) {
--
1.7.11.4
More information about the Olsr-dev
mailing list