diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-08-08 17:15:52 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-08-08 17:15:52 +0000 |
commit | 441b765de8c604440a181c139209ca84d6e8cbe7 (patch) | |
tree | af3fb744912f8dfe7beac342f45c3b2e41f42821 /sys/uvm/uvm_mmap.c | |
parent | 85da94603dcd63f34425160d9c6f20883ef3f20b (diff) |
W^X violations are only permitted for binaries marked "wxneeded" on
"wxallowed" filesystems. mmap(2) & mprotect(2) now return ENOTSUP.
(To diagnose buggy programs, consider using sysctl kern.wxabort=1 and
looking at the coredumps)
ok kettenis tedu naddy
Diffstat (limited to 'sys/uvm/uvm_mmap.c')
-rw-r--r-- | sys/uvm/uvm_mmap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/uvm/uvm_mmap.c b/sys/uvm/uvm_mmap.c index 242826a1061..81cc0b513d4 100644 --- a/sys/uvm/uvm_mmap.c +++ b/sys/uvm/uvm_mmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uvm_mmap.c,v 1.137 2016/07/13 17:52:37 kettenis Exp $ */ +/* $OpenBSD: uvm_mmap.c,v 1.138 2016/08/08 17:15:51 deraadt Exp $ */ /* $NetBSD: uvm_mmap.c,v 1.49 2001/02/18 21:19:08 chs Exp $ */ /* @@ -334,7 +334,7 @@ uvm_wxcheck(struct proc *p, char *call) setsigvec(p, SIGABRT, &sa); psignal(p, SIGABRT); } - return (0); /* ENOTSUP later */ + return (ENOTSUP); } /* |