[Olsr-dev] [PATCH v1 5/9] linux: netlink_process_link: simplify a comparison

Ferry Huberts (spam-protected)
Wed Feb 10 14:35:44 CET 2016


From: Ferry Huberts <(spam-protected)>

To make it easier to read

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

diff --git a/src/linux/kernel_routes_nl.c b/src/linux/kernel_routes_nl.c
index 3684060..da9dd6e 100644
--- a/src/linux/kernel_routes_nl.c
+++ b/src/linux/kernel_routes_nl.c
@@ -129,7 +129,7 @@ static void netlink_process_link(struct nlmsghdr *h)
 
   oif = ifaceName ? olsrif_ifwithname(ifaceName) : NULL;
 
-  if (!iface && ((ifi->ifi_flags & IFF_UP) == IFF_UP)) {
+  if (!iface && ((ifi->ifi_flags & IFF_UP) != 0)) {
     if (oif) {
       /* try to take interface up, will trigger ifchange */
       chk_if_up(oif, 3);
-- 
2.5.0




More information about the Olsr-dev mailing list