Skip to content

Commit

Permalink
Add const to geom variable
Browse files Browse the repository at this point in the history
Co-authored-by: Julien Cabieces <julien.cabieces@oslandia.com>
  • Loading branch information
2 people authored and nyalldawson committed Aug 23, 2021
1 parent 7cdad5b commit 68ab811
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/expression/qgsexpressionfunction.cpp
Expand Up @@ -3605,7 +3605,7 @@ static QVariant fcnSinuosity( const QVariantList &values, const QgsExpressionCon

static QVariant fcnStraightDistance2d( const QVariantList &values, const QgsExpressionContext *, QgsExpression *parent, const QgsExpressionNodeFunction * )
{
QgsGeometry geom = QgsExpressionUtils::getGeometry( values.at( 0 ), parent );
const QgsGeometry geom = QgsExpressionUtils::getGeometry( values.at( 0 ), parent );
const QgsCurve *curve = qgsgeometry_cast< const QgsCurve * >( geom.constGet() );
if ( !curve )
{
Expand Down

0 comments on commit 68ab811

Please sign in to comment.