mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Fixed crash when reading project file with non-existing raster file
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@7936 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
347172b1ec
commit
4565a7be6c
@ -423,8 +423,11 @@ QgsRasterLayer::~QgsRasterLayer()
|
||||
|
||||
if (mProviderKey.isEmpty())
|
||||
{
|
||||
mGdalBaseDataset->Dereference();
|
||||
GDALClose(mGdalDataset);
|
||||
if ( mGdalBaseDataset )
|
||||
{
|
||||
mGdalBaseDataset->Dereference();
|
||||
GDALClose(mGdalDataset);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user