[Olsr-dev] [PATCH v1 086/115] info: ipc_action: make the IPv6 if statement like the IPv4 one

Ferry Huberts (spam-protected)
Wed Dec 2 21:28:59 CET 2015


From: Ferry Huberts <(spam-protected)>

Signed-off-by: Ferry Huberts <(spam-protected)>
---
 lib/info/olsrd_info.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/info/olsrd_info.c b/lib/info/olsrd_info.c
index 7147c2c..69d08b5 100644
--- a/lib/info/olsrd_info.c
+++ b/lib/info/olsrd_info.c
@@ -328,7 +328,7 @@ static void ipc_action(int fd, void *data __attribute__ ((unused)), unsigned int
     }
   } else {
     /* Use in6addr_any (::) in olsr.conf to allow anybody. */
-    if (!ip6equal(&in6addr_any, &config->accept_ip.v6) && !ip6equal(&sock_addr.in6.sin6_addr, &config->accept_ip.v6)) {
+    if (!ip6equal(&sock_addr.in6.sin6_addr, &config->accept_ip.v6) && !ip6equal(&config->accept_ip.v6, &in6addr_any)) {
 #ifndef NODEBUG
       olsr_printf(1, "(%s) From host(%s) not allowed!\n", name, addr);
 #endif /* NODEBUG */
-- 
2.5.0




More information about the Olsr-dev mailing list