diff options
author | Reyk Floeter <reyk@cvs.openbsd.org> | 2016-07-22 09:31:34 +0000 |
---|---|---|
committer | Reyk Floeter <reyk@cvs.openbsd.org> | 2016-07-22 09:31:34 +0000 |
commit | cd3fcc00220c2c948715bb7aa61d00519c93a35e (patch) | |
tree | c2869d3f42539635c3f6ea328f7d01869a575497 /usr.sbin | |
parent | cb33d119acc9ddded1983315ff9824879f1d5cce (diff) |
"wpath" is needed in the parent pledge when using the /dev/switch0 device.
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/switchd/switchd.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/switchd/switchd.c b/usr.sbin/switchd/switchd.c index 57881cad45b..902e9793bef 100644 --- a/usr.sbin/switchd/switchd.c +++ b/usr.sbin/switchd/switchd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: switchd.c,v 1.5 2016/07/20 21:01:06 reyk Exp $ */ +/* $OpenBSD: switchd.c,v 1.6 2016/07/22 09:31:33 reyk Exp $ */ /* * Copyright (c) 2013-2016 Reyk Floeter <reyk@openbsd.org> @@ -175,11 +175,12 @@ main(int argc, char *argv[]) * pledge in the parent process: * stdio - for malloc and basic I/O including events. * rpath - for reload to open and read the configuration files. + * wpath - for accessing the /dev/switch device. * inet - for opening OpenFlow and device sockets. * dns - for resolving host in the configuration files. * sendfd - send sockets to child processes on reload. */ - if (pledge("stdio rpath inet dns proc sendfd", NULL) == -1) + if (pledge("stdio rpath wpath inet dns proc sendfd", NULL) == -1) fatal("pledge"); event_init(); |