--- On Thu, 7/6/12, John Emmas <johne53(a)tiscali.co.uk> wrote:
<snipped>
> Is Wine clever enough to realise that the UTF8 string needs to be converted to a locale-specific string, so that the Windows app can understand it? Or does Wine simply pass whatever characters it received, without attempting any translation? Thanks.
> John
"Use the source, Luke!"... THe relevant code is in dlls/ntdll/file.c and dlls/ntdll/path.c which do the right thing.
As a general windows programming note, in windows' land, file path related WIN32 APIs tend to have two variants, those ending with *A, and those ending with *W. The former expects ascii inputs, the latter expects WCHAR (I think it is basically UT16LE). The long answer is that wine leaves the former unchanged (except path separator translation, e.g. from unix "/" to windows "\", adding or removing drive letter prefixes, depending on the direction of translation), but will convert from utf8 to WCHAR for the latter, so that the application itself receives the right thing. It is still up to the application's author to use the right Windows APIs for reading/writing files, and whether the application itself expects ascii file paths or unicode (WCHAR) file paths.
The short answer is that wine *does* translate from unix-like to windows-like file paths so that the application receives the right stuff. You have nothing to worry about.