From: Johannes Schindelin Date: Mon, 21 Jul 2008 00:56:35 GMT Subject: Re: [PATCH v2 1/4] builtin-add.c: restructure the code for maintainability Message-ID: In-Reply-To: <1216534144-23826-1-git-send-email-gitster@pobox.com> Hi, On Sat, 19 Jul 2008, Junio C Hamano wrote: > diff --git a/builtin-add.c b/builtin-add.c > index bf13aa3..9b2ee8c 100644 > --- a/builtin-add.c > +++ b/builtin-add.c > [...] > + /* > + * If we are adding new files, we need to scan the working > + * tree to find the ones that match pathspecs; this needs > + * to be done before we read the index. > + */ This comment left me scratching my head. While I do see a breakage when reading the index first, I had the impression that it should not. I can only imagine that the other users of read_directory() depend on some funny interaction between the index and treat_directory(). Ciao, Dscho