A Turkish official says the Coast Guard has fired on and stopped a migrant ship, detaining 337 mostly Syrian refugees who were hoping to illegally reach Italy.

Gov. Ahmet Cinar of Canakkale province said Friday that the Coast Guard fired on the freighter's engine room off the Gallipoli peninsula late Thursday, after it ignored warnings to stop.

The passengers included 85 children and 68 women. They were being sheltered at a sports hall in Canakkale. Three crew members were detained.

More than 3 million people have fled the war in Syria. Recently, smugglers have been using freighters to sneak refugees to Italy.

The Dogan news agency said the migrants on board shouted "either to Italy or death" before the ship was stopped.