From b38f7723eb3cc04e8ea170413a746af9a230ecc5 Mon Sep 17 00:00:00 2001 From: Konstantin Belousov Date: Sun, 13 Jun 2010 05:24:27 +0000 Subject: In NFS clients, instead of inconsistently using #ifdef DIAGNOSTIC and #ifndef DIAGNOSTIC for debug assertions, prefer KASSERT(). Also change one #ifdef DIAGNOSTIC in the new nfs server. Submitted by: Mikolaj Golub MFC after: 2 weeks --- sys/fs/nfsserver/nfs_nfsdsocket.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'sys/fs/nfsserver/nfs_nfsdsocket.c') diff --git a/sys/fs/nfsserver/nfs_nfsdsocket.c b/sys/fs/nfsserver/nfs_nfsdsocket.c index fc6e39e63cfd..c95fef22a46a 100644 --- a/sys/fs/nfsserver/nfs_nfsdsocket.c +++ b/sys/fs/nfsserver/nfs_nfsdsocket.c @@ -364,10 +364,7 @@ nfsrvd_dorpc(struct nfsrv_descript *nd, int isdgram, * Get a locked vnode for the first file handle */ if (!(nd->nd_flag & ND_NFSV4)) { -#ifdef DIAGNOSTIC - if (nd->nd_repstat) - panic("nfsrvd_dorpc"); -#endif + KASSERT(nd->nd_repstat == 0, ("nfsrvd_dorpc")); /* * For NFSv3, if the malloc/mget allocation is near limits, * return NFSERR_DELAY. -- cgit v1.2.3