From 9e3ef0cd5b73576e2a2d56bd40af9887d1b5ef83 Mon Sep 17 00:00:00 2001 From: ptv Date: Mon, 30 Oct 2006 07:29:23 +0000 Subject: [PATCH] delete all modules at application destructor --- src/CAM/CAM_Application.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/CAM/CAM_Application.cxx b/src/CAM/CAM_Application.cxx index baabb3970..1c71b6ed1 100755 --- a/src/CAM/CAM_Application.cxx +++ b/src/CAM/CAM_Application.cxx @@ -59,6 +59,10 @@ myAutoLoad( autoLoad ) /*!Destructor. Do nothing.*/ CAM_Application::~CAM_Application() { + // delete all modules (or switch on autoDelete property of QPtrList in constructor ) + for ( ModuleListIterator it( myModules ); it.current(); ++it ) + delete it.current(); + myModules.clear(); } /*! Load modules, if \a myAutoLoad flag is true.\n -- 2.39.2