After a British proposal the 1878 Berlin Congress permitted Austria-Hungary to occupy and govern Bosnia-Herzegovina instead of Turkey, the long Brod–Zenica military railway was built to support manoeuvres and supply troops. It was completed in 1879, using the temporary tracks and rolling stock used during the construction of the recently finished Temesvár–Orsova line. The Zenica–Sarajevo extension opened in 1882, with a loading gauge the same as that used on gauge railways, which was thought to be sufficient for general traffic including passenger services.