diff options
author | phk <phk@FreeBSD.org> | 2003-07-26 07:32:23 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2003-07-26 07:32:23 +0000 |
commit | 6221ef9078c60fa7c0eff8539ec7b1d959370e2a (patch) | |
tree | 4b10a3edcceb3eb7cae2e63c46cb2b1d26c145bf /sys/fs/unionfs/union_subr.c | |
parent | e33bcc1872887407faa57becf9cde30a67fe1596 (diff) | |
download | FreeBSD-src-6221ef9078c60fa7c0eff8539ec7b1d959370e2a.zip FreeBSD-src-6221ef9078c60fa7c0eff8539ec7b1d959370e2a.tar.gz |
Add a "int fd" argument to VOP_OPEN() which in the future will
contain the filedescriptor number on opens from userland.
The index is used rather than a "struct file *" since it conveys a bit
more information, which may be useful to in particular fdescfs and /dev/fd/*
For now pass -1 all over the place.
Diffstat (limited to 'sys/fs/unionfs/union_subr.c')
-rw-r--r-- | sys/fs/unionfs/union_subr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/fs/unionfs/union_subr.c b/sys/fs/unionfs/union_subr.c index 94460cf..896a5b9 100644 --- a/sys/fs/unionfs/union_subr.c +++ b/sys/fs/unionfs/union_subr.c @@ -784,7 +784,7 @@ union_copyup(un, docopy, cred, td) * from VOP_CLOSE() */ vn_lock(lvp, LK_EXCLUSIVE | LK_RETRY, td); - error = VOP_OPEN(lvp, FREAD, cred, td); + error = VOP_OPEN(lvp, FREAD, cred, td, -1); if (error == 0 && vn_canvmio(lvp) == TRUE) error = vfs_object_create(lvp, td, cred); if (error == 0) { @@ -815,7 +815,7 @@ union_copyup(un, docopy, cred, td) for (i = 0; i < un->un_openl; i++) { (void) VOP_CLOSE(lvp, FREAD, cred, td); - (void) VOP_OPEN(uvp, FREAD, cred, td); + (void) VOP_OPEN(uvp, FREAD, cred, td, -1); } if (un->un_openl) { if (vn_canvmio(uvp) == TRUE) @@ -1130,7 +1130,7 @@ union_vn_create(vpp, un, td) if (error) return (error); - error = VOP_OPEN(vp, fmode, cred, td); + error = VOP_OPEN(vp, fmode, cred, td, -1); if (error == 0 && vn_canvmio(vp) == TRUE) error = vfs_object_create(vp, td, cred); if (error) { @@ -1340,7 +1340,7 @@ union_dircheck(struct thread *td, struct vnode **vp, struct file *fp) } if (lvp != NULLVP) { - error = VOP_OPEN(lvp, FREAD, fp->f_cred, td); + error = VOP_OPEN(lvp, FREAD, fp->f_cred, td, -1); if (error == 0 && vn_canvmio(lvp) == TRUE) error = vfs_object_create(lvp, td, fp->f_cred); if (error) { |