summaryrefslogtreecommitdiff
path: root/usr.sbin/relayd/pfe.c
diff options
context:
space:
mode:
authorReyk Floeter <reyk@cvs.openbsd.org>2016-09-02 16:14:10 +0000
committerReyk Floeter <reyk@cvs.openbsd.org>2016-09-02 16:14:10 +0000
commit41550decd9d45cb01640b6f2a186c96786189cd4 (patch)
tree831760f4c7fbe268eb207a65c8de6076d7947d99 /usr.sbin/relayd/pfe.c
parent6fa65a0da6c311cd832c5fd1a6982ed9271f45ff (diff)
Move snmp options into struct relayd_config and delay start of the
snmp subsystem until the configuration is done. OK benno@ claudio@
Diffstat (limited to 'usr.sbin/relayd/pfe.c')
-rw-r--r--usr.sbin/relayd/pfe.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.sbin/relayd/pfe.c b/usr.sbin/relayd/pfe.c
index 9c039c66b2a..012b49f24e8 100644
--- a/usr.sbin/relayd/pfe.c
+++ b/usr.sbin/relayd/pfe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfe.c,v 1.86 2016/09/02 14:45:51 reyk Exp $ */
+/* $OpenBSD: pfe.c,v 1.87 2016/09/02 16:14:09 reyk Exp $ */
/*
* Copyright (c) 2006 Pierre-Yves Ritschard <pyr@openbsd.org>
@@ -62,8 +62,6 @@ pfe_init(struct privsep *ps, struct privsep_proc *p, void *arg)
if (config_init(ps->ps_env) == -1)
fatal("failed to initialize configuration");
- snmp_init(env, PROC_PARENT);
-
if (pledge("stdio recvfd unix pf", NULL) == -1)
fatal("pledge");
@@ -207,6 +205,7 @@ pfe_dispatch_parent(int fd, struct privsep_proc *p, struct imsg *imsg)
config_getcfg(env, imsg);
init_filter(env, imsg->fd);
init_tables(env);
+ snmp_init(env, PROC_PARENT);
break;
case IMSG_CTL_START:
pfe_setup_events();