readdir() returns inaccessible name if file was created with invalid UTF-8
Jon Turney
jon.turney@dronecode.org.uk
Wed Jul 2 21:11:09 GMT 2025
On 26/06/2025 18:07, Christian Franke via Cygwin wrote:
> Corinna Vinschen via Cygwin wrote:
>> On Jun 25 16:59, Christian Franke via Cygwin wrote:
>>> On 2024年9月15日 19:47:11 +0200, Christian Franke wrote:
>>>> If a file name contains an invalid (truncated) UTF-8 sequence, open()
>>>> does not refuse to create the file. Later readdir() returns a different
>>>> name which could not be used to access the file.
>>>>[...]
>> Testcase: enable one of the "DON'T DO THIS" lines and make sure that a
> suitable file removal tool is available :-)
Christian,
I think you should already have push access to the stc repository I
setup [1], which is now run as part of the CI to check for regressions.
If you think it's useful, please consider adding this (or any of the
other STCs you've very helpfully put together) to that.
[1] https://cygwin.com/cgit/cygwin-apps/stc/
More information about the Cygwin
mailing list