Hastings was imprisoned with others in the Bengali capital, Murshidabad, while the Nawab's forces marched on Calcutta and captured it. The garrison and civilians were then locked up under appalling conditions in the Black Hole of Calcutta. For a while Hastings remained in Murshidabad and was even used by the Nawab as an intermediary, but fearing for his life, he escaped to the island of Fulta, where a number of refugees from Calcutta had taken shelter. While there, he met and married Mary Buchanan, the widow of one of the victims of the Black Hole. Shortly afterwards a British expedition from Madras under Robert Clive arrived to rescue them. Hastings served as a volunteer in Clive's forces as they retook Calcutta in January 1757. After this swift defeat, the Nawab urgently sought peace and the war came to an end. Clive was impressed with Hastings when he met him, and arranged for his return to Kasimbazar to resume his pre-war activities. Later in 1757 fighting resumed, leading to the Battle of Plassey, where Clive won a decisive victory over the Nawab. Siraj ud-Daulah was overthrown and replaced by his uncle Mir Jafar, who initiated pro-British policies. Today Mir Jafar has the reputation of a traitor in India and Bangladesh. In 1758 Hastings became the British Resident in the Bengali capital of Murshidabad – a major step forward in his career – at the instigation of Clive. His role in the city was ostensibly that of an ambassador but as Bengal came increasingly under the dominance of the East India Company he was often given the task of issuing orders to the new Nawab on behalf of Clive and the Calcutta authorities. Hastings personally sympathised with Mir Jafar and regarded many of the demands placed on him by the Company as excessive. Hastings had already developed a philosophy that was grounded in trying to establish a more understanding relationship with India's inhabitants and their rulers, and he often tried to mediate between the two sides. During Mir Jafar's reign the East India Company exerted an increasingly large role in the running of the region, and effectively took over the defence of Bengal against external invaders when Bengal's troops proved insufficient for the task. As he grew older, Mir Jafar became gradually less effective in ruling the state, and in 1760 British troops ousted him from power and replaced him with Mir Qasim.