smbfs bug introduced at smbfs_vnops.c:1.58

From: <takawata_at_jp.freebsd.org>
Date: Sun, 10 Apr 2005 11:51:21 +0900
Hi I found the bug which is introduced at smbfs_vnops.c rev 1.58

This will make instant panic when you try to access
file on mounted smbfs.

This is caused by uninitialized vp.

Index: smbfs_vnops.c
===================================================================
RCS file: /home/ncvs/src/sys/fs/smbfs/smbfs_vnops.c,v
retrieving revision 1.59
diff -u -r1.59 smbfs_vnops.c
--- smbfs_vnops.c	29 Mar 2005 13:06:58 -0000	1.59
+++ smbfs_vnops.c	10 Apr 2005 02:44:04 -0000
_at__at_ -1118,7 +1118,8 _at__at_
 		return error;
 	if (error) {		/* name was found */
 		struct vattr vattr;
-
+		
+		vp = *vpp;
 		killit = 0;
 		error = VOP_GETATTR(vp, &vattr, cnp->cn_cred, td);
 		/*
Received on Sun Apr 10 2005 - 00:53:09 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:31 UTC