summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorOrgad Shaneh <orgad.shaneh@audiocodes.com>2018-07-04 23:17:04 +0300
committerOrgad Shaneh <orgads@gmail.com>2018-07-05 10:47:42 +0000
commit4e080dcbfc8b519b041f125c53ad5f7313ac5393 (patch)
treee0bafa258121420db6df544b830523aa9bdc7478 /src
parent135c762ea0bb2c13f9568b9c85b10633f0c6ce34 (diff)
QSampleCache: Fix memory leak
and a warning on termination: QCoreApplication::postEvent: Unexpected null receiver During static deinit it is not possible to use deleteLater, as there is no event loop running at this stage. The crash that was described in QTBUG-30630 doesn't reproduce with Qt 5.10, so I guess it should be safe to just delete. Change-Id: I0c404d71e9f102018e314c890ff679f8c0952b07 Reviewed-by: VaL Doroshchuk <valentyn.doroshchuk@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/multimedia/audio/qsamplecache_p.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/multimedia/audio/qsamplecache_p.cpp b/src/multimedia/audio/qsamplecache_p.cpp
index 93010c182..43f948cef 100644
--- a/src/multimedia/audio/qsamplecache_p.cpp
+++ b/src/multimedia/audio/qsamplecache_p.cpp
@@ -132,8 +132,7 @@ QSampleCache::~QSampleCache()
for (QSample* sample : copyStaleSamples)
delete sample;
- if (m_networkAccessManager)
- m_networkAccessManager->deleteLater();
+ delete m_networkAccessManager;
}
void QSampleCache::loadingRelease()