mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-15 01:29:19 +02:00
* patch from #8480 committed. #0#0 also copied.
git-svn-id: trunk@6782 -
This commit is contained in:
parent
b7b057d570
commit
77d82e5b0a
@ -238,12 +238,13 @@ Procedure fpc_WideStr_Incr_Ref(Var S : Pointer);[Public,Alias:'FPC_WIDESTR_INCR_
|
|||||||
exit;
|
exit;
|
||||||
{$ifdef FPC_WINLIKEWIDESTRING}
|
{$ifdef FPC_WINLIKEWIDESTRING}
|
||||||
p:=NewWidestring(length(WideString(S)));
|
p:=NewWidestring(length(WideString(S)));
|
||||||
move(s^,p^,length(WideString(s))*sizeof(widechar));
|
move(s^,p^,length(WideString(s)+1)*sizeof(widechar)); // double nul also
|
||||||
s:=p;
|
s:=p;
|
||||||
{$else FPC_WINLIKEWIDESTRING}
|
{$else FPC_WINLIKEWIDESTRING}
|
||||||
{ Let's be paranoid : Constant string ??}
|
{ Let's be paranoid : Constant string ??}
|
||||||
If PWideRec(S-WideFirstOff)^.Ref<0 then exit;
|
If PWideRec(S-WideFirstOff)^.Ref<0 then
|
||||||
inclocked(PWideRec(S-WideFirstOff)^.Ref);
|
exit;
|
||||||
|
inclocked(PWideRec(S-WideFirstOff)^.Ref);
|
||||||
{$endif FPC_WINLIKEWIDESTRING}
|
{$endif FPC_WINLIKEWIDESTRING}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user