fix territory_of_point()