summaryrefslogtreecommitdiffstats
path: root/bfdd/bfdd.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 04:24:32 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 04:24:32 +0000
commit35cadacd2bb9383686753731e31bd7e145fb2506 (patch)
tree4489adbde75a837989533837185b2b8369a0bf68 /bfdd/bfdd.c
parentAdding debian version 9.1-0.1. (diff)
downloadfrr-35cadacd2bb9383686753731e31bd7e145fb2506.tar.xz
frr-35cadacd2bb9383686753731e31bd7e145fb2506.zip
Merging upstream version 10.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'bfdd/bfdd.c')
-rw-r--r--bfdd/bfdd.c28
1 files changed, 17 insertions, 11 deletions
diff --git a/bfdd/bfdd.c b/bfdd/bfdd.c
index 95066b9..243cf5c 100644
--- a/bfdd/bfdd.c
+++ b/bfdd/bfdd.c
@@ -75,6 +75,8 @@ static void sigterm_handler(void)
bfd_vrf_terminate();
+ bfdd_zclient_terminate();
+
/* Terminate and free() FRR related memory. */
frr_fini();
@@ -115,13 +117,20 @@ static const struct frr_yang_module_info *const bfdd_yang_modules[] = {
&frr_vrf_info,
};
-FRR_DAEMON_INFO(bfdd, BFD, .vty_port = 2617,
- .proghelp = "Implementation of the BFD protocol.",
- .signals = bfd_signals, .n_signals = array_size(bfd_signals),
- .privs = &bglobal.bfdd_privs,
- .yang_modules = bfdd_yang_modules,
- .n_yang_modules = array_size(bfdd_yang_modules),
+/* clang-format off */
+FRR_DAEMON_INFO(bfdd, BFD,
+ .vty_port = BFDD_VTY_PORT,
+ .proghelp = "Implementation of the BFD protocol.",
+
+ .signals = bfd_signals,
+ .n_signals = array_size(bfd_signals),
+
+ .privs = &bglobal.bfdd_privs,
+
+ .yang_modules = bfdd_yang_modules,
+ .n_yang_modules = array_size(bfdd_yang_modules),
);
+/* clang-format on */
#define OPTION_CTLSOCK 1001
#define OPTION_DPLANEADDR 2000
@@ -333,8 +342,6 @@ int main(int argc, char *argv[])
" --bfdctl Specify bfdd control socket\n"
" --dplaneaddr Specify BFD data plane address\n");
- snprintf(ctl_path, sizeof(ctl_path), BFDD_CONTROL_SOCKET,
- "", "");
while (true) {
opt = frr_getopt(argc, argv, NULL);
if (opt == EOF)
@@ -355,9 +362,8 @@ int main(int argc, char *argv[])
}
}
- if (bfdd_di.pathspace && !ctlsockused)
- snprintf(ctl_path, sizeof(ctl_path), BFDD_CONTROL_SOCKET,
- "/", bfdd_di.pathspace);
+ if (!ctlsockused)
+ snprintf(ctl_path, sizeof(ctl_path), BFDD_SOCK_NAME);
/* Initialize FRR infrastructure. */
master = frr_init();