summaryrefslogtreecommitdiffstats
path: root/sys/fs/smbfs
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2005-04-10 03:17:42 +0000
committerdelphij <delphij@FreeBSD.org>2005-04-10 03:17:42 +0000
commit4c97b619e5a8662b2c5ed791ab8e564aa85e75c5 (patch)
treebb77ec7c276ade49216664eb68855b26d8e53e9d /sys/fs/smbfs
parent7a8e8974c6883f1271b991a821221694cdddabdd (diff)
downloadFreeBSD-src-4c97b619e5a8662b2c5ed791ab8e564aa85e75c5.zip
FreeBSD-src-4c97b619e5a8662b2c5ed791ab8e564aa85e75c5.tar.gz
Initialize vp before using it. Failing to do this can cause instant
panic when trying to access a file on mounted smbfs. Submitted by: takawata at jp freebsd org
Diffstat (limited to 'sys/fs/smbfs')
-rw-r--r--sys/fs/smbfs/smbfs_vnops.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/fs/smbfs/smbfs_vnops.c b/sys/fs/smbfs/smbfs_vnops.c
index b7f08fe..268e5f8 100644
--- a/sys/fs/smbfs/smbfs_vnops.c
+++ b/sys/fs/smbfs/smbfs_vnops.c
@@ -1120,6 +1120,7 @@ smbfs_lookup(ap)
struct vattr vattr;
killit = 0;
+ vp = *vpp;
error = VOP_GETATTR(vp, &vattr, cnp->cn_cred, td);
/*
* If the file type on the server is inconsistent
OpenPOWER on IntegriCloud