LONDON - A European Union counter-piracy force arrested seven suspected pirates after a French fishing boat was attacked in the Indian Ocean, it said Wednesday.

Pirates in two skiffs opened fire on the French vessel on Tuesday, 350 nautical miles east of Somalia's capital Mogadishu, EU Navfor said in a statement.

The pirates broke off their attack after security guards on board the French boat fired warning shots, it said.

A helicopter, from a Spanish warship that also forms part of the EU force, ESPS Canarias, spotted two skiffs fleeing the area and fired warning shots, stopping the skiffs.

Crew from a German warship, the FGS Karlsruhe, then boarded the skiffs, detaining the seven suspected pirates.

The operation was unrelated to an incident Tuesday in which Somali pirates said they had seized a yacht in the Indian Ocean with a British couple on board, EU Navfor said.

The pirates typically use mother ships to sail hundreds of miles to sea and then launch attacks in small skiffs, armed with assault rifles and rocket-propelled grenade launchers.

The gangs -- some made up of former Somali fisherman angered by the presence of foreign fishing vessels in their waters -- have made tens of millions of dollars in ransoms.

(Reporting by Adrian Croft)