From: Jeff King Date: Mon, 08 Oct 2007 02:22:05 GMT Subject: Re: [PATCH] Make git-clean a builtin Message-ID: <20071008022205.GA21277@coredump.intra.peff.net> In-Reply-To: On Sun, Oct 07, 2007 at 07:17:50PM -0700, Linus Torvalds wrote: > fchdir() is not portable. > > I think it would be better to not chdir() at all. Yes, that means having > to prepend the prefix to the names, but that is what git generally does > (for that - and other - reasons). I was using the "even Solaris has it!" test, but yes, it's not POSIX. I don't know how common it actually is (for curiosity's sake, do you know of a common platform that lacks it?). But I do agree that just building up the path and avoiding the chdir at all is simple and portable. -Peff