astar: Fix update of node while marking it as processed.