From dead25d63c6cf7d21a9e3a5cd2edb070c2fdfa94 Mon Sep 17 00:00:00 2001 From: Ansgar Becker Date: Sun, 22 Oct 2023 10:57:27 +0200 Subject: [PATCH] Silence sporadic EAccessViolation in DBtreeBeforeCellPaint, when reading DbObj.Connection.Parameters, found in uploaded reports --- source/main.pas | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/main.pas b/source/main.pas index ce9f6a01..e0c29c5c 100644 --- a/source/main.pas +++ b/source/main.pas @@ -13252,7 +13252,7 @@ var DBObj: PDBObject; AllObjects: TDBObjectList; begin - if CellPaintMode=cpmPaint then begin + if CellPaintMode=cpmPaint then try DBObj := Sender.GetNodeData(Node); if DbObj.Connection.Parameters.SessionColor <> AppSettings.GetDefaultInt(asTreeBackground) then begin TargetCanvas.Brush.Color := DbObj.Connection.Parameters.SessionColor; @@ -13262,6 +13262,7 @@ begin AllObjects := DBObj.Connection.GetDBObjects(DBObj.Database); PaintColorBar(DBObj.Size, AllObjects.LargestObjectSize, TargetCanvas, CellRect); end; + except; // Silence sporadic EAccessViolation when reading DbObj.Connection.Parameters, found in uploaded reports end; end;