After the success at Yorktown, the French fleet went to the West Indies as part of a plan to invade Britain's colony of Jamaica. In April 1782 at the Battle of the Saintes, the French fleet suffered a major defeat and de Grasse was captured by the British. Both France and Britain understood this victory to restore British control of the high seas. Since 1779, Allied forces had laid siege to the British base at Gibraltar. In 1782, a major Franco-Spanish attack on Gibraltar failed, and the fort was relieved shortly afterward. This presented a major problem to Vergennes, as his treaty of alliance with the Spanish had committed the French to keep fighting until Gibraltar was under Spanish control. Failure to gain control of Gibraltar could potentially extend the war indefinitely.