The presidents of Ecuador and Peru say they have agreed to work together to try to find a peaceful solution to their long-running border dispute.
Both countries want to find a way not to fight over the border.