diff options
Diffstat (limited to 'sys/isofs/cd9660')
-rw-r--r-- | sys/isofs/cd9660/cd9660_vfsops.c | 2 | ||||
-rw-r--r-- | sys/isofs/cd9660/cd9660_vnops.c | 19 |
2 files changed, 20 insertions, 1 deletions
diff --git a/sys/isofs/cd9660/cd9660_vfsops.c b/sys/isofs/cd9660/cd9660_vfsops.c index 3d484c9..5830f03 100644 --- a/sys/isofs/cd9660/cd9660_vfsops.c +++ b/sys/isofs/cd9660/cd9660_vfsops.c @@ -616,7 +616,7 @@ cd9660_fhtovp(mp, fhp, vpp) return (ESTALE); } *vpp = nvp; - vnode_create_vobject(*vpp, 0, curthread); + vnode_create_vobject(*vpp, ip->i_size, curthread); return (0); } diff --git a/sys/isofs/cd9660/cd9660_vnops.c b/sys/isofs/cd9660/cd9660_vnops.c index bc45abe..5b3d723 100644 --- a/sys/isofs/cd9660/cd9660_vnops.c +++ b/sys/isofs/cd9660/cd9660_vnops.c @@ -61,6 +61,7 @@ __FBSDID("$FreeBSD$"); #include <isofs/cd9660/iso_rrip.h> static vop_setattr_t cd9660_setattr; +static vop_open_t cd9660_open; static vop_access_t cd9660_access; static vop_getattr_t cd9660_getattr; static vop_ioctl_t cd9660_ioctl; @@ -156,6 +157,23 @@ cd9660_access(ap) } static int +cd9660_open(ap) + struct vop_open_args /* { + struct vnode *a_vp; + int a_mode; + struct ucred *a_cred; + struct thread *a_td; + int a_fdidx; + } */ *ap; +{ + struct iso_node *ip = VTOI(ap->a_vp); + + vnode_create_vobject(ap->a_vp, ip->i_size, ap->a_td); + return 0; +} + + +static int cd9660_getattr(ap) struct vop_getattr_args /* { struct vnode *a_vp; @@ -782,6 +800,7 @@ cd9660_pathconf(ap) */ struct vop_vector cd9660_vnodeops = { .vop_default = &default_vnodeops, + .vop_open = cd9660_open, .vop_access = cd9660_access, .vop_bmap = cd9660_bmap, .vop_cachedlookup = cd9660_lookup, |