[fpc-devel] Lazarus instability on windows caused by widestrings?
Vincent Snijders
vsnijders at quicknet.nl
Thu Jun 23 14:45:00 CEST 2005
Florian Klaempfl wrote:
> Vincent Snijders wrote:
>
>
>>Hi,
>>
>>I am investigating some instabilities of lazarus and stumbled on the
>>following (from UTF8Decode).
>>
>>var
>> hs: widestring;
>>begin
>> SetLength(hs,20);
>> SetLength(hs,8);
>>end;
>>
>>In fpc_WideStr_SetLength first a string is allocated with NewWideString,
>>which calls SysAllocStringLen on windows.
>>
>>For the second SetLength, a plain reallocmem is used, where I would have
>>expected a call to SysReAllocStringLen.
>>
>>What do you think?
>
>
> This was forgotten to change :( Sending a patch is ok ;)
Don't expect a patch from me. I think this is too low level RTL,
otherwise I would have tried it out myself to be sure. Using fpc 2.0.0
for lazarus on win32 is another option, I guess.
Should I make a bug report for it?
Vincent.
More information about the fpc-devel
mailing list