Fix cpu16 error in AtomicCmpExchange

This commit is contained in:
Pierre Muller 2023-07-10 06:54:18 +02:00
parent 96921aaba3
commit ba2b29bd2c

View File

@ -2234,7 +2234,7 @@ end;
function AtomicCmpExchange(var Target: word; NewValue, Comperand: word): word; {$ifdef SYSTEMINLINE}inline{$endif};
begin
Result:=InterlockedCompareExchange(TargetNewValue, Comperand);
Result:=InterlockedCompareExchange(Target, NewValue, Comperand);
end;