The Treaty of the Triple Alliance was a treaty that allied the Empire of Brazil, Argentina, and Uruguay against Paraguay. Signed in 1865, after the outbreak of the Paraguayan War, its articles (plus a Protocol) prescribed the allies' actions both during and after the war. The war led to the near-annihilation of Paraguay. After the defeat of Paraguay in 1870, Brazil and Argentina (who were traditional enemies) hovered on the brink of mutual warfare for six years because of disputes and misunderstandings about the treaty. Background Although the Empire of Brazil and Argentina were traditional enemies, they, together with Uruguay, united against Paraguay in 1865. The causes of the war were various and have been hotly disputed by modern writers, and have even been traced back to territorial disputes between Portugal and Spain stemming from the Treaty of Tordesillas (1494). "Indeed the Paraguayan War was just the last chapter in a two-century conflict between the Spanish and Portuguese over the region". But for the purposes of this article, it may be enough to outline the geopolitical situation and the immediate antecedents of the treaty. In the middle of the 19th century, vast tracts of South America were undeveloped, railways were few and short, and surfaced roads practically did not exist. So navigable rivers were "vital arteries". Of particular relevance were the Paraná and Paraguay rivers. Using the Paraná-Paraguay system, quite large ships could steam 1,870 miles (3,010 km) upriver from Buenos Aires well into the Brazilian Mato Grosso province. These rivers were of crucial importance to landlocked Paraguay, to Brazil and to the trade of some Argentine provinces. It was, as wrote D.S. Chandler Thus Buenos Aires Province under Juan Manuel de Rosas had restricted river traffic to put pressure on upstream Paraguay, and Paraguay under Carlos Antonio López had done the same to put pressure on Brazil. Furthermore, immense territories were disputed. Not effectively occupied by anyone, except the aboriginal inhabitants, they had no obvious international boundaries. There was a boundary dispute between Brazil and Paraguay going back to colonial times, and there were large areas in dispute between Paraguay and Argentina in the Gran Chaco and in the territory of Misiones. Then, there were no obvious and accepted principles according to which they might have been resolved, and no established practice of international arbitration existed. In international law victory in war was a recognised way of acquiring territory.