Fix leak in QgsRelief

This commit is contained in:
Nyall Dawson 2018-03-11 16:28:55 +10:00
parent 540d692c56
commit 3315db0fe7

View File

@ -452,6 +452,9 @@ gdal::dataset_unique_ptr QgsRelief::openOutputFile( GDALDatasetH inputDataset, G
//create three band raster (red, green, blue)
gdal::dataset_unique_ptr outputDataset( GDALCreate( outputDriver, mOutputFile.toUtf8().constData(), xSize, ySize, 3, GDT_Byte, papszOptions ) );
CSLDestroy( papszOptions );
papszOptions = nullptr;
if ( !outputDataset )
{
return nullptr;