Several test functions use a centrally-allocated QSplitter for their tests. This object was allocated in initTestCase(), but cleanTestCase(), while present, was empty, so nothing deleted the object again. Fix by deleting the object in cleanupTestCase(). Initialize the member variable to nullptr so that the delete is well-formed even if initTestCase() for some reason didn't run (or didn't run to completion). Amends the start of the public history, where this function read #if defined(QT3_SUPPORT) delete qApp->mainWidget(); #endif which was already leaking if QT3_SUPPORT wasn't defined. Pick-to: 6.8 6.5 5.15 Change-Id: I43e5d8921a9c097f252e11709f25bc622fc8fe15 Reviewed-by: Axel Spoerl <axel.spoerl@qt.io> (cherry picked from commit fbaa37633580dcf6b8ec3cd4a0da8d85902de2ea) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
…
…
Description
Languages
C++
84.3%
HTML
4.9%
C
3.9%
CMake
3.6%
Objective-C++
2%
Other
0.8%