From ef98d23ce3b29d88f8592ff36304b0b275fca69f Mon Sep 17 00:00:00 2001 From: yamt Date: Fri, 26 Sep 2003 14:08:45 +0000 Subject: [PATCH] do delayed truncation in nfs_getattr. --- sys/nfs/nfs_vnops.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/sys/nfs/nfs_vnops.c b/sys/nfs/nfs_vnops.c index 7a538547a5d2..60dafe409edd 100644 --- a/sys/nfs/nfs_vnops.c +++ b/sys/nfs/nfs_vnops.c @@ -1,4 +1,4 @@ -/* $NetBSD: nfs_vnops.c,v 1.180 2003/09/26 11:51:53 yamt Exp $ */ +/* $NetBSD: nfs_vnops.c,v 1.181 2003/09/26 14:08:45 yamt Exp $ */ /* * Copyright (c) 1989, 1993 @@ -39,7 +39,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: nfs_vnops.c,v 1.180 2003/09/26 11:51:53 yamt Exp $"); +__KERNEL_RCSID(0, "$NetBSD: nfs_vnops.c,v 1.181 2003/09/26 14:08:45 yamt Exp $"); #include "opt_nfs.h" #include "opt_uvmhist.h" @@ -614,6 +614,12 @@ nfs_getattr(v) */ if (np->n_flag & (NACC | NUPD)) np->n_flag |= NCHG; + + /* + * if we have delayed truncation, do it now. + */ + nfs_delayedtruncate(vp); + /* * First look in the cache. */