Subject: Re: CVS commit: src/sys/fs/ntfs
To: Bill Studenmund <wrstuden@netbsd.org>
From: Jaromir Dolecek <jdolecek@netbsd.org>
List: tech-kern
Date: 04/10/2003 21:22:23
Bill Studenmund wrote:
> No. From vnode.src:
> 
> vop_rename {
>         IN WILLRELE struct vnode *fdvp;
>         IN WILLRELE struct vnode *fvp;
>         IN struct componentname *fcnp;
>         IN WILLPUT struct vnode *tdvp;
>         IN WILLRELE struct vnode *tvp;
>         IN struct componentname *tcnp;
> };
> 
> rename only has one WILLPUT, so we don't have to worry about a
> dual-vput(). Or at least that was my thinking. :-)

Hmm, true. But current ntfs_rename(), and ufs_rename() which was
source of the info, has

	if (ap->a_tvp)
		vput(ap->a_tvp);

so tvp should actually be WILLPUT, or ufs_vnops.c is wrong :)

And it's necessary to add a check against NULL vp in either case.

Jaromir

> > I'll give it a try and see if it works.
> 
> Thanks!
> 
> Take care,
> 
> Bill
> 


-- 
Jaromir Dolecek <jdolecek@NetBSD.org>            http://www.NetBSD.org/
-=- We should be mindful of the potential goal, but as the tantric    -=-
-=- Buddhist masters say, ``You may notice during meditation that you -=-
-=- sometimes levitate or glow.   Do not let this distract you.''     -=-