const TrackType::Endpoint &ep2 = tlinks[j]->get_type().get_endpoint(tlinks[j]->get_endpoint_by_link(**i));
path = get_turnout(tid2);
// Ignore a linked turnout with some other path set
- if(path>0 && !(ep2.paths&(1<<path)))
+ if(path>=0 && !(ep2.paths&(1<<path)))
continue;
}