Index: djopt.c =================================================================== --- djopt.c (revision 30841) +++ djopt.c (revision 30842) @@ -896,7 +896,7 @@ int th = djmax(p->BoundingBox.X2 - p->BoundingBox.X1, p->BoundingBox.Y2 - p->BoundingBox.Y1); th /= 2; if (dist(l->s->x, l->s->y, c->x, c->y) > th - && dist(l->e->x, l->e->y, c->x, c->y) > th && pcb_isc_pstk_line(p, l->line)) { + && dist(l->e->x, l->e->y, c->x, c->y) > th && pcb_isc_pstk_line(pcb_find0, p, l->line)) { return split_line(l, c); } }