From 977da6cc019f33b3102792dbf069039c1df33a80 Mon Sep 17 00:00:00 2001 From: dg Date: Mon, 6 Feb 1995 02:20:40 +0000 Subject: Changed order of release of vnode/object to fix a problem where the vnode is freed with an old object still attached (subsequently causing a panic). Fixes NFS server panic "object/pager mismatch". Submitted by: John Dyson --- sys/nfsclient/nfs_subs.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'sys/nfsclient/nfs_subs.c') diff --git a/sys/nfsclient/nfs_subs.c b/sys/nfsclient/nfs_subs.c index f281360..7b2cf64 100644 --- a/sys/nfsclient/nfs_subs.c +++ b/sys/nfsclient/nfs_subs.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)nfs_subs.c 8.3 (Berkeley) 1/4/94 - * $Id: nfs_subs.c,v 1.7 1994/10/17 17:47:37 phk Exp $ + * $Id: nfs_subs.c,v 1.8 1995/01/09 16:05:08 davidg Exp $ */ /* @@ -1207,17 +1207,20 @@ retry: int nfsrv_vput( struct vnode *vp) { if( (vp->v_flag & VVMIO) && vp->v_vmdata) { + vput( vp); vm_object_deallocate( (vm_object_t) vp->v_vmdata); + } else { + vput( vp); } - vput( vp); return 0; } int nfsrv_vrele( struct vnode *vp) { if( (vp->v_flag & VVMIO) && vp->v_vmdata) { + vrele( vp); vm_object_deallocate( (vm_object_t) vp->v_vmdata); + } else { + vrele( vp); } - vrele( vp); return 0; } - -- cgit v1.1