Skip to content

Commit 0594453

Browse files
committedMar 22, 2013
Fix parsing bug in wkb -> geos export
1 parent 8f9ca6f commit 0594453

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

‎src/core/qgsgeometry.cpp‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4556,7 +4556,7 @@ bool QgsGeometry::exportWkbToGeos()
45564556
int *nPoints;
45574557
int *numRings;
45584558
int *numPolygons;
4559-
int numLineStrings;
4559+
int *numLineStrings;
45604560
int idx, jdx, kdx;
45614561
unsigned char *ptr;
45624562
QgsPoint pt;
@@ -4642,9 +4642,9 @@ bool QgsGeometry::exportWkbToGeos()
46424642
case QGis::WKBMultiLineString:
46434643
{
46444644
QVector<GEOSGeometry*> lines;
4645-
numLineStrings = ( int )( mGeometry[5] );
4645+
numLineStrings = ( int* )( mGeometry + 5 );
46464646
ptr = ( mGeometry + 9 );
4647-
for ( jdx = 0; jdx < numLineStrings; jdx++ )
4647+
for ( jdx = 0; jdx < *numLineStrings; jdx++ )
46484648
{
46494649
QgsPolyline sequence;
46504650

0 commit comments

Comments
 (0)
Please sign in to comment.