mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-15 14:29:31 +02:00
Revert r34745 #fe6abb4c2e. Fixing the memory leak causes a crash when Lazarus starts.
git-svn-id: trunk@34750 -
This commit is contained in:
parent
9e3711ff17
commit
5b3a5be476
@ -1635,9 +1635,6 @@ var
|
||||
P: Pointer;
|
||||
i, j: integer;
|
||||
begin
|
||||
// check here for Description. Only RGBA data can be processed here.
|
||||
if not CheckDescription then
|
||||
Exit;
|
||||
if CreateNewData then
|
||||
begin
|
||||
GetMem(AData, DataSize);
|
||||
@ -1650,6 +1647,11 @@ begin
|
||||
AData := P;
|
||||
end;
|
||||
|
||||
// check here for Description. Only RGBA data can be processed here.
|
||||
if not CheckDescription then
|
||||
Exit;
|
||||
|
||||
|
||||
case ADrawEffect of
|
||||
gdeNormal: ;
|
||||
gdeDisabled:
|
||||
@ -1718,13 +1720,6 @@ begin
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
if CreateNewData then
|
||||
begin
|
||||
Move(AData^, Data^, DataSize);
|
||||
P := Data;
|
||||
FreeMem(AData, DataSize);
|
||||
end;
|
||||
Data := P;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user