Re: [BUG] Unicode filenames handling in `git log --stat`
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Aug 10, 2022, 15:53 UTC
- Message-ID
- <xmqqiln0p01z.fsf@gitster.g>
- In-Reply-To
- <20220810084017.gnnodcbt5lyibbf6@tb-raspi4>
Torsten Bögershausen <tboegi@web.de> writes:
Show 8 quoted lines
> git log --stat > [snip] > Arger.txt | 1 + > Ärger.txt | 1 + > 2 files changed, 2 insertions(+) > > From this very first experiment I would suspect that we use > strlen() somewhere rather then utf8.c::git_gcwidth()
Yeah, that does sound like the case, and quite honestly, knowing that the diffstat code is way older than unicode-width code, which was added by you in mid 2014, I am not all that surprised if we used to use strlen() throughout and we still do by mistake.
Thanks for a doze of sanity.