summaryrefslogtreecommitdiffstats
path: root/ospfd/ospf_spf.c
diff options
context:
space:
mode:
authorMichal Ruprich <michalruprich@gmail.com>2022-09-06 12:25:01 +0200
committerMichal Ruprich <michalruprich@gmail.com>2022-09-06 12:34:15 +0200
commitec3bb054c331f9d928ac21a1747e0f921b51dfbc (patch)
treed9901123a3e022f9dc59c3e76d9aa0e5b5c62f2d /ospfd/ospf_spf.c
parentMerge pull request #11902 from SaiGomathiN/igmp-to-gm (diff)
downloadfrr-ec3bb054c331f9d928ac21a1747e0f921b51dfbc.tar.xz
frr-ec3bb054c331f9d928ac21a1747e0f921b51dfbc.zip
ospfd: Adding SUPPORT_OSPF_API define in ospf_spf.c
It is not possible to build ospf_spf.c file with --disable-ospfapi because ospf_apiserver.c has SUPPORT_OSPF_API around all function definitions and that results in an undefined reference to the ospf_apiserver_notify_reachable function error while building. Signed-off-by: Michal Ruprich <mruprich@redhat.com>
Diffstat (limited to 'ospfd/ospf_spf.c')
-rw-r--r--ospfd/ospf_spf.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ospfd/ospf_spf.c b/ospfd/ospf_spf.c
index 46492ff6b..4edc1de81 100644
--- a/ospfd/ospf_spf.c
+++ b/ospfd/ospf_spf.c
@@ -48,7 +48,10 @@
#include "ospfd/ospf_sr.h"
#include "ospfd/ospf_ti_lfa.h"
#include "ospfd/ospf_errors.h"
+
+#ifdef SUPPORT_OSPF_API
#include "ospfd/ospf_apiserver.h"
+#endif
/* Variables to ensure a SPF scheduled log message is printed only once */
@@ -1895,7 +1898,9 @@ static void ospf_spf_calculate_schedule_worker(struct thread *thread)
/* Update all routers routing table */
ospf->oall_rtrs = ospf->all_rtrs;
ospf->all_rtrs = all_rtrs;
+#ifdef SUPPORT_OSPF_API
ospf_apiserver_notify_reachable(ospf->oall_rtrs, ospf->all_rtrs);
+#endif
/* Free old ABR/ASBR routing table */
if (ospf->old_rtrs)