Quantcast
Channel: DotSpatial
Viewing all articles
Browse latest Browse all 3973

Created Unassigned: bug IndexOutOfRange EnvelopeExt.Intersection(this IEnvelope self, ILineSegment segment) [24604]

$
0
0
DotSpatial.Topology.EnvelopeExt.Intersection(this IEnvelope self, ILineSegment segment)

This method throws an IndexOutOfRangeException because we try to check more than two borderpoints
if we already have two Points we break instead

Before
Line 845

for (int i = 0; i < 4; i++)
{
borderPoints[count] = border[i].Intersection(segment);
if (borderPoints[count] != null)
{
count++;
}
}

After
Line 845

for (int i = 0; i < 4; i++)
{
borderPoints[count] = border[i].Intersection(segment);
if (borderPoints[count] != null)
{
count++;
if (count > 1)
break;
}
}

Viewing all articles
Browse latest Browse all 3973

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>