mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-02 22:09:48 +00:00
Merge pull request #10814 from manojvn/2896483
ospf6d: observed crash in ospf6_decrement_retrans_count.
This commit is contained in:
commit
a51061fa50
@ -464,11 +464,28 @@ void ospf6_flood_interface(struct ospf6_neighbor *from, struct ospf6_lsa *lsa,
|
||||
lsa->header->type, lsa->header->id,
|
||||
lsa->header->adv_router, on->retrans_list);
|
||||
if (!old) {
|
||||
struct ospf6_lsa *orig;
|
||||
struct ospf6_lsdb *lsdb;
|
||||
|
||||
if (is_debug)
|
||||
zlog_debug(
|
||||
"Increment %s from retrans_list of %s",
|
||||
lsa->name, on->name);
|
||||
ospf6_increment_retrans_count(lsa);
|
||||
|
||||
/* Increment the retrans count on the original
|
||||
* copy of LSA if present, to maintain the
|
||||
* counter consistency.
|
||||
*/
|
||||
|
||||
lsdb = ospf6_get_scoped_lsdb(lsa);
|
||||
orig = ospf6_lsdb_lookup(
|
||||
lsa->header->type, lsa->header->id,
|
||||
lsa->header->adv_router, lsdb);
|
||||
if (orig)
|
||||
ospf6_increment_retrans_count(orig);
|
||||
else
|
||||
ospf6_increment_retrans_count(lsa);
|
||||
|
||||
ospf6_lsdb_add(ospf6_lsa_copy(lsa),
|
||||
on->retrans_list);
|
||||
thread_add_timer(
|
||||
|
@ -132,6 +132,8 @@ void ospf6_lsdb_add(struct ospf6_lsa *lsa, struct ospf6_lsdb *lsdb)
|
||||
(*lsdb->hook_add)(lsa);
|
||||
}
|
||||
} else {
|
||||
lsa->retrans_count = old->retrans_count;
|
||||
|
||||
if (OSPF6_LSA_IS_CHANGED(old, lsa)) {
|
||||
if (OSPF6_LSA_IS_MAXAGE(lsa)) {
|
||||
if (lsdb->hook_remove) {
|
||||
|
Loading…
Reference in New Issue
Block a user