[geos-commits] r3850 - trunk/include/geos/geom
svn_geos at osgeo.org
svn_geos at osgeo.org
Thu Jul 25 14:00:17 PDT 2013
Author: strk
Date: 2013-07-25 14:00:17 -0700 (Thu, 25 Jul 2013)
New Revision: 3850
Modified:
trunk/include/geos/geom/CoordinateList.h
Log:
Fix CoordinateList.closeRing() use of past-the-end operator
Modified: trunk/include/geos/geom/CoordinateList.h
===================================================================
--- trunk/include/geos/geom/CoordinateList.h 2013-07-25 20:51:22 UTC (rev 3849)
+++ trunk/include/geos/geom/CoordinateList.h 2013-07-25 21:00:17 UTC (rev 3850)
@@ -159,9 +159,9 @@
}
void closeRing()
{
- if(!coords.empty() && ! (*(coords.begin())).equals(*(coords.end())))
+ if(!coords.empty() && ! (*(coords.begin())).equals(*(coords.rbegin())))
{
- Coordinate c= *(coords.begin());
+ const Coordinate &c = *(coords.begin());
coords.insert(coords.end(),c);
}
}
More information about the geos-commits
mailing list