Qt: Fix memory leak in LogController
Vicki Pfau vi@endrift.com
Wed, 04 Jul 2018 12:47:09 -0700
2 files changed,
5 insertions(+),
0 deletions(-)
M
src/platform/qt/LogController.cpp
→
src/platform/qt/LogController.cpp
@@ -25,6 +25,10 @@ connect(this, &LogController::levelsDisabled, &s_global, &LogController::disableLevels);
} } +LogController::~LogController() { + mLogFilterDeinit(&m_filter); +} + LogController::Stream LogController::operator()(int category, int level) { return Stream(this, category, level); }
M
src/platform/qt/LogController.h
→
src/platform/qt/LogController.h
@@ -35,6 +35,7 @@ };
public: LogController(int levels, QObject* parent = nullptr); + ~LogController(); int levels() const { return m_filter.defaultLevels; } mLogFilter* filter() { return &m_filter; }