Skip to content

Commit 220b5e8

Browse files
committedMay 30, 2019
Fix histogram bindings
Hopfully fixes #29700
1 parent 2274d56 commit 220b5e8

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
 

‎python/core/auto_generated/raster/qgsrasterinterface.sip.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,8 +346,8 @@ Returns a band histogram. Histograms are cached in providers.
346346
maximum = PyFloat_AsDouble( a3 );
347347
}
348348

349-
QgsRasterHistogram h = sipCpp->histogram( a0, a1, minimum, maximum, *a4, a5, a6, a7 );
350-
sipRes = &h;
349+
QgsRasterHistogram *h = new QgsRasterHistogram( sipCpp->histogram( a0, a1, minimum, maximum, *a4, a5, a6, a7 ) );
350+
sipRes = h;
351351
%End
352352

353353

‎src/core/raster/qgsrasterinterface.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,8 +378,8 @@ class CORE_EXPORT QgsRasterInterface
378378
maximum = PyFloat_AsDouble( a3 );
379379
}
380380

381-
QgsRasterHistogram h = sipCpp->histogram( a0, a1, minimum, maximum, *a4, a5, a6, a7 );
382-
sipRes = &h;
381+
QgsRasterHistogram *h = new QgsRasterHistogram( sipCpp->histogram( a0, a1, minimum, maximum, *a4, a5, a6, a7 ) );
382+
sipRes = h;
383383
% End
384384
#endif
385385

0 commit comments

Comments
 (0)
Please sign in to comment.