From 68b7b9fad9678e4ccd0ec44e176184936ce0d8cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=BDeljan=20Rikalo?= Date: Mon, 13 Jun 2022 14:28:11 +0200 Subject: [PATCH] Qt,Qt5: use Release() instead of Destroy() to prevent potential crash. --- components/lclextensions/include/qt/delphicompat.inc | 2 +- components/lclextensions/include/qt5/delphicompat.inc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/lclextensions/include/qt/delphicompat.inc b/components/lclextensions/include/qt/delphicompat.inc index 6376719174..8c42ba0142 100644 --- a/components/lclextensions/include/qt/delphicompat.inc +++ b/components/lclextensions/include/qt/delphicompat.inc @@ -241,7 +241,7 @@ procedure TQtTimerEx.signalWidgetDestroyed; cdecl; begin Stop; FTimerList.Delete(FHandle, FID); - Destroy; + Release; end; procedure TQtTimerEx.signalTimeout; cdecl; diff --git a/components/lclextensions/include/qt5/delphicompat.inc b/components/lclextensions/include/qt5/delphicompat.inc index dca193738e..b7c8bd89be 100644 --- a/components/lclextensions/include/qt5/delphicompat.inc +++ b/components/lclextensions/include/qt5/delphicompat.inc @@ -241,7 +241,7 @@ procedure TQtTimerEx.signalWidgetDestroyed; cdecl; begin Stop; FTimerList.Delete(FHandle, FID); - Destroy; + Release; end; procedure TQtTimerEx.signalTimeout; cdecl;