In 1864 Castilla condemned the international policies of Pezet, only to be jailed and exiled to Gibraltar. During his absence the historic Battle of Callao took place, which became Spain's final and unsuccessful move to reconquer independent Peru.