From: Lou Berger Date: Thu, 27 Oct 2022 19:12:23 +0000 (+0000) Subject: ospfd: remove assert on zero length LSA - which is permitted by spec X-Git-Tag: base_8.5~289^2~1 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=15c4dd82dba35467c598d48407dc1238983bb31b;p=mirror%2Ffrr.git ospfd: remove assert on zero length LSA - which is permitted by spec Signed-off-by: Lou Berger --- diff --git a/ospfd/ospf_lsa.c b/ospfd/ospf_lsa.c index c67181cba6..ade75ad5e3 100644 --- a/ospfd/ospf_lsa.c +++ b/ospfd/ospf_lsa.c @@ -3596,7 +3596,8 @@ int ospf_lsa_different(struct ospf_lsa *l1, struct ospf_lsa *l2, && CHECK_FLAG((l1->flags ^ l2->flags), OSPF_LSA_RECEIVED)) return 1; /* May be a stale LSA in the LSBD */ - assert(l1->size > OSPF_LSA_HEADER_SIZE); + if (l1->size == OSPF_LSA_HEADER_SIZE) + return 0; /* nothing to compare */ p1 = (char *)l1->data; p2 = (char *)l2->data;