void BlockAllocator::turnout_path_changing(Track &track)
{
- BlockList::iterator i = find_if(blocks.begin(), blocks.end(), BlockMatch(track.get_block()));
+ BlockList::iterator i = find_if(cur_blocks_end, blocks.end(), BlockMatch(track.get_block()));
if(i!=blocks.end())
{
++i;