Re: UTF-8 and case-insensitivity

tridge
2004-02-17T23:21:44Z

Neil,

> I thought the value of a case-insensitive filenames was for
> legacy applications which have been written to the WIN32 API and took
> lots of liberties with "pretty-casing" filenames between readdir and
> open.

No, thats a common misconception. It does happen (the "pretty-casing")
but its relatively rare these days. The real problem is *proving* that
a file doesn't exist. If a file does exist then there are all sorts of
heuristic and cache mechanisms that can be used to get the real
filename quickly on average, but if you have to prove absolutely that
a file does not exist then all of that stuff is pretty much useless.

Samba (and any other system that wants case-insensitive semantics on
Linux) can't make do with "oh, it probably doesn't exist". That way
leads to data loss. You have to know with 100% certainty that the file
doesn't exist in any case combination.

Unfortunately, that is also the hardest thing to do.

Cheers, Tridge