From owner-svn-src-all@FreeBSD.ORG Wed Dec 10 14:49:55 2008 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1B891106564A; Wed, 10 Dec 2008 14:49:55 +0000 (UTC) (envelope-from dfr@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0C67B8FC17; Wed, 10 Dec 2008 14:49:55 +0000 (UTC) (envelope-from dfr@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id mBAEntRk033108; Wed, 10 Dec 2008 14:49:55 GMT (envelope-from dfr@svn.freebsd.org) Received: (from dfr@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id mBAEntQs033107; Wed, 10 Dec 2008 14:49:55 GMT (envelope-from dfr@svn.freebsd.org) Message-Id: <200812101449.mBAEntQs033107@svn.freebsd.org> From: Doug Rabson Date: Wed, 10 Dec 2008 14:49:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r185860 - head/sys/nfsserver X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Dec 2008 14:49:55 -0000 Author: dfr Date: Wed Dec 10 14:49:54 2008 New Revision: 185860 URL: http://svn.freebsd.org/changeset/base/185860 Log: We need to pass a structure with enough space for an NFSv2 filehandle to nfs_srvmtofh_xx otherwise bad things happen when an NFSv2 client tries to make a request. Modified: head/sys/nfsserver/nfs_fha.c Modified: head/sys/nfsserver/nfs_fha.c ============================================================================== --- head/sys/nfsserver/nfs_fha.c Wed Dec 10 14:06:08 2008 (r185859) +++ head/sys/nfsserver/nfs_fha.c Wed Dec 10 14:49:54 2008 (r185860) @@ -162,7 +162,7 @@ static void fha_extract_info(struct svc_req *req, struct fha_info *i) { struct mbuf *md = req->rq_args; - fhandle_t fh; + nfsfh_t fh; caddr_t dpos = mtod(md, caddr_t); static u_int64_t random_fh = 0; int error; @@ -205,11 +205,11 @@ fha_extract_info(struct svc_req *req, st goto out; /* Grab the filehandle. */ - error = nfsm_srvmtofh_xx(&fh, v3, &md, &dpos); + error = nfsm_srvmtofh_xx(&fh.fh_generic, v3, &md, &dpos); if (error) goto out; - i->fh = *(const u_int64_t *)(fh.fh_fid.fid_data); + i->fh = *(const u_int64_t *)(fh.fh_generic.fh_fid.fid_data); /* Content ourselves with zero offset for all but reads. */ if (procnum != NFSPROC_READ)