|
From: | Paul Eggert |
Subject: | Re: [PATCH v2] canonicalize-lgpl: Canonicalize casing too for MinGW. |
Date: | Sat, 11 Dec 2021 18:39:22 -0800 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.1 |
On 12/11/21 03:35, Jan Nieuwenhuizen wrote:
It looks like the inode returned by stat is always 0 on MinGW (at least it is under wine), so also when choosing this approach we would need to special case our client code for MinGW?
Yes, you'll have problems on such platforms. For ideas about this, please see the last several lines of:
https://www.gnu.org/software/gnulib/manual/html_node/sys_002fstat_002eh.html (in particular the "partial workaround").Since you're doing all this merely as an optimization, you can avoid doing the optimization on nonstandard platforms where stat is unreliable; that way, your code should still work even on nonstandard platforms, while having the optimized performance on standard platforms.
[Prev in Thread] | Current Thread | [Next in Thread] |