LazReport, check for avoiding AV from Luiz Americo, issue #16405

git-svn-id: trunk@25199 -
This commit is contained in:
jesus 2010-05-05 02:12:01 +00:00
parent 2d12587b11
commit f3cc81cdd4

View File

@ -9392,7 +9392,7 @@ begin
frGetDataSetAndField(lrGetUnBrackedStr(p1), DataSet, Field);
end;
if (DataSet <> nil) and AggrBand.Visible then
if (DataSet <> nil) and (Field <> nil) and AggrBand.Visible then
begin
min := 1e200; max := -1e200; sum := 0; count := 0; avg := 0;
BM:=DataSet.GetBookMark;
@ -9434,7 +9434,7 @@ begin
end;
val := d;
end
else if DataSet = nil then
else if (DataSet = nil) or (Field = nil) then
begin
s1 := Trim(string(p2));
if s1 = '' then