# possible 'git --dirstat=0' buglet in 1.7.0.4?

2 messages from 2010-11-12 to 2010-11-16. Participants: Mike Coleman, Junio C Hamano.
Thread: https://gitlist.dev/t/25726

## Mike Coleman, 2010-11-12 14:33

Subject: possible 'git --dirstat=0' buglet in 1.7.0.4?
Message-ID: <AANLkTi=wZ8MhU0NUw9as-kw8Lhr=TFBK2BY7MFRQvOct@mail.gmail.com>
URL: https://gitlist.dev/e/AANLkTi%3DwZ8MhU0NUw9as-kw8Lhr%3DTFBK2BY7MFRQvOct%40mail.gmail.com

```
I noticed just now that the '--dirstat=0' flag still seems to filter
out some diffs, even though I would expect the '0' to mean "don't
filter anything".  If there's another flag that says "don't filter", I
missed it.  Could this be a rounding or off-by-one error?

Mike

```

## Junio C Hamano, 2010-11-16 18:05

Subject: Re: possible 'git --dirstat=0' buglet in 1.7.0.4?
Message-ID: <7v7hgdi1pp.fsf@alter.siamese.dyndns.org>
URL: https://gitlist.dev/e/7v7hgdi1pp.fsf%40alter.siamese.dyndns.org
In-Reply-To: <AANLkTi=wZ8MhU0NUw9as-kw8Lhr=TFBK2BY7MFRQvOct@mail.gmail.com>

```
Mike Coleman <tutufan@gmail.com> writes:

> I noticed just now that the '--dirstat=0' flag still seems to filter
> out some diffs, even though I would expect the '0' to mean "don't
> filter anything".  If there's another flag that says "don't filter", I
> missed it.  Could this be a rounding or off-by-one error?

We seem to internally compute in per-mille (see gather_dirstat() in diff.c)
so if your changes are too small to be rounded off to zero there,...

I think you can remove the "if (permille)" there to make it not filter at
all when dir->percent is set to 0, but I didn't look carefully.

```
