diff options
author | kib <kib@FreeBSD.org> | 2011-03-25 14:00:36 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2011-03-25 14:00:36 +0000 |
commit | fc2bd01611a5db99f84b5d7f3109b9f9274f548d (patch) | |
tree | b38a121140636385de89e7dedcbbafed47879d2c /sys/kern/vfs_syscalls.c | |
parent | 948b7589fcf961fe76d3f86de580dccb0814fdb7 (diff) | |
download | FreeBSD-src-fc2bd01611a5db99f84b5d7f3109b9f9274f548d.zip FreeBSD-src-fc2bd01611a5db99f84b5d7f3109b9f9274f548d.tar.gz |
Add O_CLOEXEC flag to open(2) and fhopen(2).
The new function fallocf(9), that is renamed falloc(9) with added
flag argument, is provided to facilitate the merge to stable branch.
Reviewed by: jhb
MFC after: 1 week
Diffstat (limited to 'sys/kern/vfs_syscalls.c')
-rw-r--r-- | sys/kern/vfs_syscalls.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 9046d1c..fe66591 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -1069,7 +1069,7 @@ kern_openat(struct thread *td, int fd, char *path, enum uio_seg pathseg, else flags = FFLAGS(flags); - error = falloc(td, &nfp, &indx); + error = fallocf(td, &nfp, &indx, flags); if (error) return (error); /* An extra reference on `nfp' has been held for us by falloc(). */ @@ -4488,7 +4488,7 @@ fhopen(td, uap) * end of vn_open code */ - if ((error = falloc(td, &nfp, &indx)) != 0) { + if ((error = fallocf(td, &nfp, &indx, fmode)) != 0) { if (fmode & FWRITE) vp->v_writecount--; goto bad; |