From: Morten Welinder Date: Mon, 29 Oct 2007 22:59:00 GMT Subject: Re: [PATCH] Speedup scanning for excluded files. Message-ID: <118833cc0710291559kbd874a8o8111b9495090ef27@mail.gmail.com> In-Reply-To: <200710290959.32538.lars@trolltech.com> > + } else if (x->flags & EXC_FLAG_ENDSWITH) { > + if (!strcmp(exclude + 1, pathname + pathlen -x->patternlen + 1)) Is there some guarantee that the result of that subtraction is still within the string? Morten