[fpc-devel] RTL: file system functions results encoding

vvzh.home at gmail.com vvzh.home at gmail.com
Tue Mar 11 15:37:50 CET 2008


On Mon, 10 Mar 2008, Michael Van Canneyt wrote:

> On Mon, 10 Mar 2008, Vladimir wrote:
>
>> Hi,
>> 
>> Working with SysUtils.FindFirst and FindNext routines I found that the encoding
>> of resulting TSearchRec record fields differs across platforms.
>> Under Windows it seems to be ANSI and under Linux it seems to be UTF-8.
>> The problem is that application expects the same encoding everywhere.
>> Is there any way to determine the resulting encoding to convert fields
>> to the encoding I need?

> In short: no. But you shouldn't have to ?
> The result depends on the system calls used by the FindFirst/FindNext calls,
> and since the system calls are by definition system dependent, so you know
> on which platform what encoding is used.

Thanks, Michael. I'll try to implement some abstraction layer then.






More information about the fpc-devel mailing list