summaryrefslogtreecommitdiffstats
path: root/staticd/static_main.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 /staticd/static_main.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 'staticd/static_main.c')
-rw-r--r--staticd/static_main.c29
1 files changed, 17 insertions, 12 deletions
diff --git a/staticd/static_main.c b/staticd/static_main.c
index 165fb4d..9468a98 100644
--- a/staticd/static_main.c
+++ b/staticd/static_main.c
@@ -53,7 +53,7 @@ struct option longopts[] = { { 0 } };
/* Master of threads. */
struct event_loop *master;
-struct mgmt_be_client *mgmt_be_client;
+static struct mgmt_be_client *mgmt_be_client;
static struct frr_daemon_info staticd_di;
@@ -113,23 +113,26 @@ static const struct frr_yang_module_info *const staticd_yang_modules[] = {
&frr_staticd_info,
};
-#define STATIC_VTY_PORT 2616
-
/*
* NOTE: .flags == FRR_NO_SPLIT_CONFIG to avoid reading split config, mgmtd will
* do this for us now
*/
-FRR_DAEMON_INFO(staticd, STATIC, .vty_port = STATIC_VTY_PORT,
+/* clang-format off */
+FRR_DAEMON_INFO(staticd, STATIC,
+ .vty_port = STATIC_VTY_PORT,
+ .proghelp = "Implementation of STATIC.",
- .proghelp = "Implementation of STATIC.",
+ .signals = static_signals,
+ .n_signals = array_size(static_signals),
- .signals = static_signals,
- .n_signals = array_size(static_signals),
+ .privs = &static_privs,
- .privs = &static_privs, .yang_modules = staticd_yang_modules,
- .n_yang_modules = array_size(staticd_yang_modules),
+ .yang_modules = staticd_yang_modules,
+ .n_yang_modules = array_size(staticd_yang_modules),
- .flags = FRR_NO_SPLIT_CONFIG);
+ .flags = FRR_NO_SPLIT_CONFIG,
+);
+/* clang-format on */
int main(int argc, char **argv, char **envp)
{
@@ -165,8 +168,10 @@ int main(int argc, char **argv, char **envp)
hook_register(routing_conf_event,
routing_control_plane_protocols_name_validate);
-
- routing_control_plane_protocols_register_vrf_dependency();
+ hook_register(routing_create,
+ routing_control_plane_protocols_staticd_create);
+ hook_register(routing_destroy,
+ routing_control_plane_protocols_staticd_destroy);
/*
* We set FRR_NO_SPLIT_CONFIG flag to avoid reading our config, but we