File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -1377,7 +1377,7 @@ QString QgsGdalProvider::buildPyramids( QList<QgsRasterPyramid> const & theRaste
1377
1377
}
1378
1378
1379
1379
// are we using Erdas Imagine external overviews?
1380
- const char * myConfigUseRRD = CPLGetConfigOption ( " USE_RRD" , " NO" );
1380
+ char * myConfigUseRRD = strdup ( CPLGetConfigOption ( " USE_RRD" , " NO" ) );
1381
1381
if ( theFormat == PyramidsErdas )
1382
1382
CPLSetConfigOption ( " USE_RRD" , " YES" );
1383
1383
else
@@ -1471,6 +1471,7 @@ QString QgsGdalProvider::buildPyramids( QList<QgsRasterPyramid> const & theRaste
1471
1471
// emit drawingProgress( 0, 0 );
1472
1472
// restore former USE_RRD config (Erdas)
1473
1473
CPLSetConfigOption ( " USE_RRD" , myConfigUseRRD );
1474
+ free (myConfigUseRRD);
1474
1475
return " FAILED_NOT_SUPPORTED" ;
1475
1476
}
1476
1477
else
@@ -1487,6 +1488,7 @@ QString QgsGdalProvider::buildPyramids( QList<QgsRasterPyramid> const & theRaste
1487
1488
1488
1489
// restore former USE_RRD config (Erdas)
1489
1490
CPLSetConfigOption ( " USE_RRD" , myConfigUseRRD );
1491
+ free (myConfigUseRRD);
1490
1492
1491
1493
QgsDebugMsg ( " Pyramid overviews built" );
1492
1494
You can’t perform that action at this time.
0 commit comments