Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern set VEXEC if FEXEC is set.



details:   https://anonhg.NetBSD.org/src/rev/37b29b30da6e
branches:  trunk
changeset: 463925:37b29b30da6e
user:      christos <christos%NetBSD.org@localhost>
date:      Sun Sep 15 20:24:25 2019 +0000

description:
set VEXEC if FEXEC is set.

diffstat:

 sys/kern/vfs_vnops.c |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (28 lines):

diff -r 81c0a8a03a59 -r 37b29b30da6e sys/kern/vfs_vnops.c
--- a/sys/kern/vfs_vnops.c      Sun Sep 15 20:23:50 2019 +0000
+++ b/sys/kern/vfs_vnops.c      Sun Sep 15 20:24:25 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vfs_vnops.c,v 1.200 2019/03/07 11:09:48 hannken Exp $  */
+/*     $NetBSD: vfs_vnops.c,v 1.201 2019/09/15 20:24:25 christos Exp $ */
 
 /*-
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_vnops.c,v 1.200 2019/03/07 11:09:48 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_vnops.c,v 1.201 2019/09/15 20:24:25 christos Exp $");
 
 #include "veriexec.h"
 
@@ -309,6 +309,9 @@
        if ((fflags & FREAD) != 0) {
                permbits = VREAD;
        }
+       if ((fflags & FEXEC) != 0) {
+               permbits |= VEXEC;
+       }
        if ((fflags & (FWRITE | O_TRUNC)) != 0) {
                permbits |= VWRITE;
                if (vp->v_type == VDIR) {



Home | Main Index | Thread Index | Old Index