Skip to content
Permalink
Browse files

Fix some leaks

  • Loading branch information
nyalldawson committed Sep 23, 2015
1 parent 366331c commit 8a949fa1a61daa76f5319a40960ca5d81e51caf0
@@ -239,6 +239,8 @@ QgsDataItem::~QgsDataItem()
mDeferredDelete = true;
mFutureWatcher->waitForFinished();
}

delete mFutureWatcher;
}

QString QgsDataItem::pathComponent( const QString &string )
@@ -237,6 +237,7 @@ QgsProviderRegistry::~QgsProviderRegistry()
if ( cleanupFunc )
cleanupFunc();
}
delete it->second;
++it;
}
}
@@ -172,6 +172,7 @@ void TestQgsDataItem::testDirItemChildren()
}

}
qDeleteAll( children );

delete dirItem;
}
@@ -103,8 +103,6 @@ void TestQgsRasterSubLayer::initTestCase()
myRasterFileInfo.completeBaseName() );
qDebug() << "raster metadata: " << mpRasterLayer->dataProvider()->metadata();
mReport += "raster metadata: " + mpRasterLayer->dataProvider()->metadata();

QgsMapLayerRegistry::instance()->addMapLayer( mpRasterLayer );
}
else
{
@@ -115,6 +113,7 @@ void TestQgsRasterSubLayer::initTestCase()
//runs after all tests
void TestQgsRasterSubLayer::cleanupTestCase()
{
delete mpRasterLayer;
QgsApplication::exitQgis();
QString myReportFile = QDir::tempPath() + "/qgistest.html";
QFile myFile( myReportFile );

0 comments on commit 8a949fa

Please sign in to comment.
You can’t perform that action at this time.