In 1799, the Fourth Anglo-Mysore War saw the defeat of the King of Mysore, thus bringing an end to the Portuguese's primary rival in the region. Over time, the purpose of the fort shifted from being a defensive structure, to a prison. This fort housed a government prison till 1955.