Re: [PATCH v9 4/8] utf8: add function to detect a missing UTF-16/32 BOM
- From
Lars Schneider <larsxschneider@gmail.com>
- Date
- Mar 6, 2018, 23:00 UTC
- Message-ID
- <CF78BB76-B42C-4A83-B18C-3FBAB0339346@gmail.com>
- In-Reply-To
- <xmqq8tb43jfe.fsf@gitster-ct.c.googlers.com>
Show 16 quoted lines
> On 06 Mar 2018, at 23:53, Junio C Hamano <gitster@pobox.com> wrote: > > Lars Schneider <larsxschneider@gmail.com> writes: > >>> Also "UTF16" or other spelling >>> the platform may support but this code fails to recognise will go >>> unchecked. >> >> That is true. However, I would assume all iconv implementations use the >> same encoding names for UTF encodings, no? That means UTF16 would never be >> valid. Would you agree? > > After seeing "UTF16" and others in "iconv -l | grep -i utf" output, > I am not sure what you mean by "Would you agree?" People can say in > their .gitattributes file that this path is in "UTF16" without dash > and that is what will be fed to this coe, no?
On macOS I don't see UTF16... but I just checked on my Linux box and there it is. Consequently, we need to check both versions: with and without dash.
I'll reroll ASAP (I try to do it first thing in the morning).
Thanks, Lars