Re: [PATCH 3/9] count_pathspec(): return number of elements in pathspec
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- May 10, 2011, 13:29 UTC
- Message-ID
- <BANLkTiniUzKM2P4PzqYaaVunN7-WjpkYmw@mail.gmail.com>
- In-Reply-To
- <1305006678-4051-4-git-send-email-gitster@pobox.com>
On Tue, May 10, 2011 at 12:51 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 5 quoted lines
> When fed a non-empty argv[], get_pathspec(prefix, argv) used to always > return an array of string that has the same number of elements as argv[] > had, but with ":" (work at toplevel without any path limit) magic pathspec > it can return zero elements. Passing the result from get_pathspec() to > this function will always give the correct number of pathspec elements.
And use the new function in builtin/rm.c too? A good cleanup while you're touching cmd_rm()..
-- Duy