diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-10-18 03:17:49 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2015-10-18 03:17:49 +0000 |
commit | ef0048419ec8f789e17a23ab6946a350fcc5c2ee (patch) | |
tree | 6f20244637be0357626e913183e7f38fe29e97c4 /sbin/savecore/savecore.c | |
parent | 3ea52149631644c343081755c65b3bba37446834 (diff) |
after kmem is open and setup, pledge "stdio rpath wpath cpath"
seems to be working. commiting to get feedback from people who crash.
Diffstat (limited to 'sbin/savecore/savecore.c')
-rw-r--r-- | sbin/savecore/savecore.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c index 86845f532e9..feb8baec3ff 100644 --- a/sbin/savecore/savecore.c +++ b/sbin/savecore/savecore.c @@ -1,4 +1,4 @@ -/* $OpenBSD: savecore.c,v 1.54 2015/10/18 03:13:07 deraadt Exp $ */ +/* $OpenBSD: savecore.c,v 1.55 2015/10/18 03:17:48 deraadt Exp $ */ /* $NetBSD: savecore.c,v 1.26 1996/03/18 21:16:05 leo Exp $ */ /*- @@ -171,6 +171,11 @@ main(int argc, char *argv[]) (void)time(&now); kmem_setup(); + if (pledge("stdio rpath wpath cpath", NULL) == -1) { + syslog(LOG_ERR, "pledge: %m"); + exit(1); + } + if (clear) { clear_dump(); return (0); |