Source-Changes-HG archive

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

[src/ad-namecache]: src/sys/kern LK_SHARED for VOP_ACCESS().



details:   https://anonhg.NetBSD.org/src/rev/a00fc507b37d
branches:  ad-namecache
changeset: 850522:a00fc507b37d
user:      ad <ad%NetBSD.org@localhost>
date:      Fri Jan 17 21:53:01 2020 +0000

description:
LK_SHARED for VOP_ACCESS().

diffstat:

 sys/kern/exec_script.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r f166fbc877f3 -r a00fc507b37d sys/kern/exec_script.c
--- a/sys/kern/exec_script.c    Fri Jan 17 21:47:22 2020 +0000
+++ b/sys/kern/exec_script.c    Fri Jan 17 21:53:01 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: exec_script.c,v 1.80 2019/09/15 20:21:12 christos Exp $        */
+/*     $NetBSD: exec_script.c,v 1.80.2.1 2020/01/17 21:53:01 ad Exp $  */
 
 /*
  * Copyright (c) 1993, 1994, 1996 Christopher G. Demetriou
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: exec_script.c,v 1.80 2019/09/15 20:21:12 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: exec_script.c,v 1.80.2.1 2020/01/17 21:53:01 ad Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_script.h"
@@ -216,7 +216,7 @@
         * close all open fd's when the start.  That kills this
         * method of implementing "safe" set-id and x-only scripts.
         */
-       vn_lock(epp->ep_vp, LK_EXCLUSIVE | LK_RETRY);
+       vn_lock(epp->ep_vp, LK_SHARED | LK_RETRY);
        error = VOP_ACCESS(epp->ep_vp, VREAD, l->l_cred);
        VOP_UNLOCK(epp->ep_vp);
        if (error == EACCES



Home | Main Index | Thread Index | Old Index