diff options
author | 2011-07-07 23:45:00 +0000 | |
---|---|---|
committer | 2011-07-07 23:45:00 +0000 | |
commit | 8ef87afd5654a8ea3f411d8d94175094ee500bd3 (patch) | |
tree | 66e3e7a8586f6dad4e4a4d39f1b17c995f6a9d18 /sys/kern/exec_script.c | |
parent | deraadt says disable bluetooth everywhere else too (diff) | |
download | wireguard-openbsd-8ef87afd5654a8ea3f411d8d94175094ee500bd3.tar.xz wireguard-openbsd-8ef87afd5654a8ea3f411d8d94175094ee500bd3.zip |
Add new syscall entries to support the openat(2) family of functions
added in POSIX Issue 7: openat(), mknodat(), mkfifoat(), linkat(),
symlinkat(), unlinkat(), faccessat(), fstatat(), readlinkat(),
fchmodat(), fchownat(), utimensat(), renameat(), and mkdirat().
This diff mostly just refactors the existing sys_foo() logic into a
common dofooat() function that can then be called by both sys_foo()
and sys_fooat(). Some of the new system calls support new flags to
control their behavior, and proper support for these will be added in
subsequent diffs.
Incorporating suggestions from thib@, guenther@, and tedu@.
ok tedu@, thib@, deraadt@, guenther@
Diffstat (limited to 'sys/kern/exec_script.c')
-rw-r--r-- | sys/kern/exec_script.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/exec_script.c b/sys/kern/exec_script.c index b48dd20f337..dc1cc381b84 100644 --- a/sys/kern/exec_script.c +++ b/sys/kern/exec_script.c @@ -1,4 +1,4 @@ -/* $OpenBSD: exec_script.c,v 1.25 2007/10/29 14:12:19 chl Exp $ */ +/* $OpenBSD: exec_script.c,v 1.26 2011/07/07 23:45:00 matthew Exp $ */ /* $NetBSD: exec_script.c,v 1.13 1996/02/04 02:15:06 christos Exp $ */ /* @@ -200,6 +200,7 @@ check_shell: #endif /* set up the parameters for the recursive check_exec() call */ + epp->ep_ndp->ni_dirfd = AT_FDCWD; epp->ep_ndp->ni_dirp = shellname; epp->ep_ndp->ni_segflg = UIO_SYSSPACE; epp->ep_flags |= EXEC_INDIR; |