summaryrefslogtreecommitdiff
path: root/zebra/connected.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2015-12-15 05:22:48 -0800
committerDonald Sharp <sharpd@cumulusnetworks.com>2015-12-15 05:22:48 -0800
commitf11b863d69e62d54168d75f3cc2018103b9a7e34 (patch)
treef690f32607e7432821bbabeb0cfb622419aaf380 /zebra/connected.c
parentca208d065c064692a334dff8612b7049475d4214 (diff)
zebra: Fix crash in connected.c due to RA change
Back out original null pointer fix targeted it was the wrong fix. Basically when a ip address is deleted the RA code was waiting till after the connected pointer was deleted to set the RA appropriately. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com> Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
Diffstat (limited to 'zebra/connected.c')
-rw-r--r--zebra/connected.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/zebra/connected.c b/zebra/connected.c
index b2fababc1b..f040e9d362 100644
--- a/zebra/connected.c
+++ b/zebra/connected.c
@@ -67,15 +67,15 @@ connected_withdraw (struct connected *ifc)
/* The address is not in the kernel anymore, so clear the flag */
UNSET_FLAG(ifc->conf, ZEBRA_IFC_QUEUED);
+ /* Enable RA suppression if there are no IPv6 addresses on this interface */
+ if (! ipv6_address_configured(ifc->ifp))
+ ipv6_nd_suppress_ra_set (ifc->ifp, RA_SUPPRESS);
+
if (!CHECK_FLAG (ifc->conf, ZEBRA_IFC_CONFIGURED))
{
listnode_delete (ifc->ifp->connected, ifc);
connected_free (ifc);
}
-
- /* Enable RA suppression if there are no IPv6 addresses on this interface */
- if (! ipv6_address_configured(ifc->ifp))
- ipv6_nd_suppress_ra_set (ifc->ifp, RA_SUPPRESS);
}
static void