[PATCH v11 1/2] ntdll: Introduce new nt_to_unix_file_name_with_case helper.

Alexandre Julliard julliard at winehq.org
Thu May 20 12:22:17 CDT 2021


Gabriel Ivăncescu <gabrielopcode at gmail.com> writes:

> On 20/05/2021 19:40, Alexandre Julliard wrote:
>> Gabriel Ivăncescu <gabrielopcode at gmail.com> writes:
>> 
>>> Which optionally returns the original case of the last path component.
>>>
>>> Signed-off-by: Gabriel Ivăncescu <gabrielopcode at gmail.com>
>>> ---
>>>   dlls/ntdll/unix/file.c | 66 +++++++++++++++++++++++++++---------------
>>>   1 file changed, 43 insertions(+), 23 deletions(-)
>> There doesn't seem to be any need for a new nt_to_unix_file_name
>> helper. You can simply copy the last path component separately from the
>> Unix name lookup, it doesn't require any file system access.
>> 
>
> So I should go with the previous approach then (obviously with fixes)?
>
> Or, what if I just add an optional parameter to nt_to_unix_file_name
> to return the case of last path? Or is that not desirable either?

The nt_to_unix_file_name() functions are already complex enough, we
shouldn't add more code to them if not absolutely necessary.

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list