From: deraadt Date: Sat, 10 Oct 2015 20:57:00 +0000 (+0000) Subject: pledge "stdio rpath wpath cpath proc exec"; this spawns cpp. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=84489e75d943bd25a3d87156b4f7581848230fd1;p=openbsd pledge "stdio rpath wpath cpath proc exec"; this spawns cpp. ok doug --- diff --git a/usr.bin/rpcgen/rpc_main.c b/usr.bin/rpcgen/rpc_main.c index dec139fc6a8..6003e1133a7 100644 --- a/usr.bin/rpcgen/rpc_main.c +++ b/usr.bin/rpcgen/rpc_main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rpc_main.c,v 1.30 2015/08/20 22:32:41 deraadt Exp $ */ +/* $OpenBSD: rpc_main.c,v 1.31 2015/10/10 20:57:00 deraadt Exp $ */ /* $NetBSD: rpc_main.c,v 1.9 1996/02/19 11:12:43 pk Exp $ */ /* @@ -140,6 +140,9 @@ main(int argc, char *argv[]) { struct commandline cmd; + if (pledge("stdio rpath wpath cpath proc exec", NULL) == -1) + perror("pledge"); + (void) memset((char *) &cmd, 0, sizeof(struct commandline)); clear_args(); if (!parseargs(argc, argv, &cmd))