Extract pointer value for mnt_stat from vp after the NULL check, not

before.

Coverity ID:	134394
Found with:	Coverity Prevent (tm)
This commit is contained in:
rwatson 2006-06-06 08:43:27 +00:00
parent 62e2a7bdfd
commit abd4afc6be

View File

@ -115,12 +115,13 @@ audit_record_write(struct vnode *vp, struct ucred *cred, struct thread *td,
int ret;
long temp;
struct vattr vattr;
struct statfs *mnt_stat = &vp->v_mount->mnt_stat;
struct statfs *mnt_stat;
int vfslocked;
if (vp == NULL)
return (0);
mnt_stat = &vp->v_mount->mnt_stat;
vfslocked = VFS_LOCK_GIANT(vp->v_mount);
/*