From owner-cvs-all@FreeBSD.ORG Sun Apr 17 09:39:10 2005 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6B49916A4CE for ; Sun, 17 Apr 2005 09:39:10 +0000 (GMT) Received: from relay03.pair.com (relay03.pair.com [209.68.5.17]) by mx1.FreeBSD.org (Postfix) with SMTP id 616FD43D41 for ; Sun, 17 Apr 2005 09:39:09 +0000 (GMT) (envelope-from silby@silby.com) Received: (qmail 39496 invoked from network); 17 Apr 2005 09:39:08 -0000 Received: from unknown (HELO localhost) (unknown) by unknown with SMTP; 17 Apr 2005 09:39:08 -0000 X-pair-Authenticated: 209.68.2.70 Date: Sun, 17 Apr 2005 04:39:04 -0500 (CDT) From: Mike Silbersack To: David Schultz In-Reply-To: <20050417032618.GA65952@VARK.MIT.EDU> Message-ID: <20050417043659.P5292@odysseus.silby.com> References: <200504162347.j3GNlJUA010418@repoman.freebsd.org> <20050417014050.GA640@VARK.MIT.EDU> <20050416213839.A694@odysseus.silby.com> <20050417032618.GA65952@VARK.MIT.EDU> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed cc: cvs-src@FreeBSD.ORG cc: src-committers@FreeBSD.ORG cc: cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/sys/fs/msdosfs msdosfs_lookup.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Apr 2005 09:39:10 -0000 On Sat, 16 Apr 2005, David Schultz wrote: > Cool. By the way, if you want to come up with a better fix, > please feel free. I think the right fix is along the lines of: > > int msdosfs_vop_lookup(dvp, vpp, cnp) { > do the usual checks (dvp is VDIR, R/O FS, VOP_ACCESS(dvp)); > char *oldname = cnp->cn_name; > char newname[12] = unix2dosfn(oldname); > cnp->cn_name = newname; > error = cache_lookup(dvp, vpp, cnp); > cnp->cn_name = oldname; > if (error /* i.e., in cache */) > return (error); > return (msdosfs_lookup(dvp, vpp, cnp)); > } > > I don't use msdosfs enough to adequately test this, though. I use it every few days when transferring files to a USB flash drive, but that's about it. I only became interested in it when it started corrupting files on me, and I only wrote the regression test for this case-sensitivity problem because it was so easy. So anyway, I do not plan on messing with msdosfs internals. :) Mike "Silby" Silbersack