mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 23:30:22 +02:00
LCL, fix DbImage leak if stream is empty, slightly modified from Stratis Aravias patch in issue #25750
git-svn-id: trunk@44334 -
This commit is contained in:
parent
d0d17505d9
commit
ca052fe4aa
@ -182,6 +182,8 @@ begin
|
|||||||
s := FDataLink.DataSet.CreateBlobStream(FDataLink.Field,bmRead);
|
s := FDataLink.DataSet.CreateBlobStream(FDataLink.Field,bmRead);
|
||||||
if (S=Nil) or (s.Size = 0) then
|
if (S=Nil) or (s.Size = 0) then
|
||||||
begin
|
begin
|
||||||
|
if s<>nil then
|
||||||
|
s.Free;
|
||||||
Picture.Clear;
|
Picture.Clear;
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user