From: Klemens Nanni Date: Fri, 25 May 2018 05:56:27 +0000 (+0200) Subject: Pledge on OpenBSD X-Git-Url: https://git.danieliu.xyz/?a=commitdiff_plain;h=f40f86fa873bc4acccdf3d929aa0f786993ae31d;p=dwm.git Pledge on OpenBSD --- diff --git a/dwm.c b/dwm.c index bb95e26..09feae3 100644 --- a/dwm.c +++ b/dwm.c @@ -2137,6 +2137,10 @@ main(int argc, char *argv[]) die("dwm: cannot open display"); checkotherwm(); setup(); +#ifdef __OpenBSD__ + if (pledge("stdio proc exec", NULL) == -1) + die("pledge"); +#endif /* __OpenBSD__ */ scan(); run(); cleanup();