From owner-svn-src-all@FreeBSD.ORG Fri Mar 20 10:59:07 2009 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 3F6E51065673; Fri, 20 Mar 2009 10:59:07 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2D85B8FC0C; Fri, 20 Mar 2009 10:59:07 +0000 (UTC) (envelope-from kib@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 n2KAx678000184; Fri, 20 Mar 2009 10:59:06 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n2KAx61l000183; Fri, 20 Mar 2009 10:59:06 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <200903201059.n2KAx61l000183@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 20 Mar 2009 10:59:06 +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: r190142 - head/sys/kern 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: Fri, 20 Mar 2009 10:59:08 -0000 Author: kib Date: Fri Mar 20 10:59:06 2009 New Revision: 190142 URL: http://svn.freebsd.org/changeset/base/190142 Log: The nc_nlen member of the struct namecache contains the length of the cached name, not the length + 1. PR: 132620, 132542 Reported by: bf2006a yahoo com Tested by: bf2006a, pho Reviewed by: marcus Modified: head/sys/kern/vfs_cache.c Modified: head/sys/kern/vfs_cache.c ============================================================================== --- head/sys/kern/vfs_cache.c Fri Mar 20 10:47:16 2009 (r190141) +++ head/sys/kern/vfs_cache.c Fri Mar 20 10:59:06 2009 (r190142) @@ -997,7 +997,7 @@ vn_fullpath1(struct thread *td, struct v ncp = TAILQ_FIRST(&vp->v_cache_dst); if (ncp != NULL) { MPASS(vp->v_dd == NULL || ncp->nc_dvp == vp->v_dd); - buflen -= ncp->nc_nlen - 1; + buflen -= ncp->nc_nlen; for (i = ncp->nc_nlen - 1; i >= 0 && bp != buf; i--) *--bp = ncp->nc_name[i]; if (bp == buf) {