diff --git a/graph.cpp b/graph.cpp index 47c23e3..3fcfa02 100644 --- a/graph.cpp +++ b/graph.cpp @@ -70,7 +70,7 @@ bool Graph::crosses_edge(Vertex* a, Vertex* b) for (list::iterator subcursor = v->neighbors.begin(); subcursor != v->neighbors.end(); subcursor++) { - Vertex* w = *cursor; + Vertex* w = *subcursor; if (MathUtils::lines_intersect(a->x, a->y, b->x, b->y, v->x, v->y, w->x, w->y))