From owner-svn-src-all@FreeBSD.ORG Fri Jun 5 16:44:42 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 A54941065672; Fri, 5 Jun 2009 16:44:42 +0000 (UTC) (envelope-from marcus@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 93D398FC22; Fri, 5 Jun 2009 16:44:42 +0000 (UTC) (envelope-from marcus@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 n55GigHO031501; Fri, 5 Jun 2009 16:44:42 GMT (envelope-from marcus@svn.freebsd.org) Received: (from marcus@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n55Gigtw031500; Fri, 5 Jun 2009 16:44:42 GMT (envelope-from marcus@svn.freebsd.org) Message-Id: <200906051644.n55Gigtw031500@svn.freebsd.org> From: Joe Marcus Clarke Date: Fri, 5 Jun 2009 16:44:42 +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: r193518 - 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, 05 Jun 2009 16:44:43 -0000 Author: marcus (doc,ports committer) Date: Fri Jun 5 16:44:42 2009 New Revision: 193518 URL: http://svn.freebsd.org/changeset/base/193518 Log: Unlock the cache lock before returning when we run out of buffer space trying to fill in the full path name. Reported by: David Naylor Approved by: kib Modified: head/sys/kern/vfs_cache.c Modified: head/sys/kern/vfs_cache.c ============================================================================== --- head/sys/kern/vfs_cache.c Fri Jun 5 16:43:47 2009 (r193517) +++ head/sys/kern/vfs_cache.c Fri Jun 5 16:44:42 2009 (r193518) @@ -1140,8 +1140,10 @@ vn_fullpath1(struct thread *td, struct v error = vn_vptocnp_locked(&vp, buf, &buflen); if (error) return (error); - if (buflen == 0) + if (buflen == 0) { + CACHE_RUNLOCK(); return (ENOMEM); + } buf[--buflen] = '/'; slash_prefixed = 1; } @@ -1169,6 +1171,7 @@ vn_fullpath1(struct thread *td, struct v if (error) break; if (buflen == 0) { + CACHE_RUNLOCK(); error = ENOMEM; SDT_PROBE(vfs, namecache, fullpath, return, error, startvp, NULL, 0, 0);