Skip to content

Commit

Permalink
Merge pull request FRRouting#16810 from anlancs/fix/pimd-interface-cr…
Browse files Browse the repository at this point in the history
…ash-commands

pimd: fix crash for two commands
  • Loading branch information
donaldsharp committed Sep 12, 2024
2 parents bf1fa1b + 27b682a commit 0848587
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pimd/pim_nb_config.c
Original file line number Diff line number Diff line change
Expand Up @@ -2058,6 +2058,10 @@ int lib_interface_pim_address_family_bsm_modify(struct nb_cb_modify_args *args)
case NB_EV_APPLY:
ifp = nb_running_get_entry(args->dnode, NULL, true);
pim_ifp = ifp->info;
if (!pim_ifp) {
pim_ifp = pim_if_new(ifp, false, true, false, false);
ifp->info = pim_ifp;
}
pim_ifp->bsm_enable = yang_dnode_get_bool(args->dnode, NULL);

break;
Expand All @@ -2083,6 +2087,10 @@ int lib_interface_pim_address_family_unicast_bsm_modify(
case NB_EV_APPLY:
ifp = nb_running_get_entry(args->dnode, NULL, true);
pim_ifp = ifp->info;
if (!pim_ifp) {
pim_ifp = pim_if_new(ifp, false, true, false, false);
ifp->info = pim_ifp;
}
pim_ifp->ucast_bsm_accept =
yang_dnode_get_bool(args->dnode, NULL);

Expand Down

0 comments on commit 0848587

Please sign in to comment.