From 453c25cdbb80fae40b8b77a57bcd8d69f612ca71 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 4 Feb 2015 21:06:11 -0600 Subject: [PATCH] Minor logic simplification --- net/icmpv6/icmpv6_autoconfig.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/net/icmpv6/icmpv6_autoconfig.c b/net/icmpv6/icmpv6_autoconfig.c index e688cbecbbb..06d795bbe02 100644 --- a/net/icmpv6/icmpv6_autoconfig.c +++ b/net/icmpv6/icmpv6_autoconfig.c @@ -513,8 +513,6 @@ int icmpv6_autoconfig(FAR struct net_driver_s *dev) { ndbg("ERROR: Failed send neighbor advertisement: %d\n", ret); netdev_ifdown(dev); - net_unlock(save); - return ret; } /* Leave the network up and return success (even though things did not @@ -522,7 +520,7 @@ int icmpv6_autoconfig(FAR struct net_driver_s *dev) */ net_unlock(save); - return OK; + return ret; } /* 5. Router Direction: The router provides direction to the node on how to