On Tue, May 23, 2017 at 8:52 AM, Junio C Hamano <gits...@pobox.com> wrote:
> Samuel Lijin <sxli...@gmail.com> writes:
>
>> @@ -931,6 +961,7 @@ int cmd_clean(int argc, const char **argv, const char 
>> *prefix)
>>                      prefix, argv);
>>
>>       fill_directory(&dir, &pathspec);
>> +     correct_untracked_entries(&dir);
>>
>>       for (i = 0; i < dir.nr; i++) {
>>               struct dir_entry *ent = dir.entries[i];
>
> You used to set SHOW_IGNORED_TOO and KEEP_UNTRACKED_CONTENTS in
> dir.flags early in the function, and then free dir.entries[] and
> dir.ignored[] after we are done.  They are gone in this version.
>
> Intended?

Embarrassingly, no. Rerolling.

>> diff --git a/t/t7300-clean.sh b/t/t7300-clean.sh
>> index 3a2d709c2..7b36954d6 100755
>> --- a/t/t7300-clean.sh
>> +++ b/t/t7300-clean.sh
>> @@ -653,7 +653,7 @@ test_expect_success 'git clean -d respects pathspecs 
>> (pathspec is prefix of dir)
>>       test_path_is_dir foobar
>>  '
>>
>> -test_expect_failure 'git clean -d skips untracked dirs containing ignored 
>> files' '
>> +test_expect_success 'git clean -d skips untracked dirs containing ignored 
>> files' '
>>       echo /foo/bar >.gitignore &&
>>       echo ignoreme >>.gitignore &&
>>       rm -rf foo &&

Reply via email to