Skip to content
Permalink
Browse files
Fix Coverity null pointer dereference warning
  • Loading branch information
nyalldawson committed Mar 21, 2017
1 parent e17c263 commit 51c1d670917d9e84a5b60cb88668c01605d29a75
Showing with 2 additions and 2 deletions.
  1. +2 −2 tests/src/core/testqgsgeometry.cpp
@@ -4040,11 +4040,11 @@ void TestQgsGeometry::directionNeutralSegmentation()
{
//Tests, if segmentation of a circularstring is the same in both directions
QString CWCircularStringWkt( QStringLiteral( "CIRCULARSTRING( 0 0, 0.5 0.5, 0.83 7.33 )" ) );
QgsCircularString *CWCircularString = dynamic_cast<QgsCircularString *>( QgsGeometryFactory::geomFromWkt( CWCircularStringWkt ) );
QgsCircularString *CWCircularString = static_cast<QgsCircularString *>( QgsGeometryFactory::geomFromWkt( CWCircularStringWkt ) );
QgsLineString *CWLineString = CWCircularString->curveToLine();

QString CCWCircularStringWkt( QStringLiteral( "CIRCULARSTRING( 0.83 7.33, 0.5 0.5, 0 0 )" ) );
QgsCircularString *CCWCircularString = dynamic_cast<QgsCircularString *>( QgsGeometryFactory::geomFromWkt( CCWCircularStringWkt ) );
QgsCircularString *CCWCircularString = static_cast<QgsCircularString *>( QgsGeometryFactory::geomFromWkt( CCWCircularStringWkt ) );
QgsLineString *CCWLineString = CCWCircularString->curveToLine();
QgsLineString *reversedCCWLineString = CCWLineString->reversed();

0 comments on commit 51c1d67

Please sign in to comment.