The Rock of GibraltarCredit:Paul Grover Defence sources said British military personnel are subject to both UK and local law when posted to Gibraltar. UK military police took the lead in investigations related to service personnel carrying out their duties, local police took the lead in other investigations. But sources said there were often “grey areas” that needed to be resolved between the two sides. Officers from the Royal Gibraltar Police (RGP) also this week carried out searches of three Ministry of Defence establishments.The row over jurisdiction is understood to have begun when local police tried to investigate the serviceman, who was already part of a UK inquiry into alleged offences involving indecent images of children.Royal Gibraltar Police wanted to examine computer equipment to establish if an offence had been committed in the territory.But when investigating officers tried to serve a warrant signed by the Chief Justice of Gibraltar, they were allegedly refused access to an MoD barracks. Officers later learned the serviceman was to be transported back to the UK, sparking the runway standoff that left hundreds of travellers stranded for nearly two hours. The plane was only allowed on its way once the suspect had been taken off. A handful of British military units are stationed on the territory, for defence and training.Credit:MoD Want the best of The Telegraph direct to your email and WhatsApp? Sign up to our free twice-daily Front Page newsletter and new audio briefings. The RGP says it has primacy over all criminal matters in the territory.A statement from the local police said: “Officers of the Royal Gibraltar Police have arrested three senior military officials and executed a number of search warrants at various MoD establishments.”They have been arrested on suspicion of attempting to pervert the course of justice and for conspiring to pervert the course of justice. The investigation concerns the events on the runway on Wednesday February 8.”Neither the MoD nor the police would last night comment on the whether the serviceman who sparked the row was still in Gibraltar, but he is still believed to be under investigation.The Gibraltar Chronicle reported one of the locations searched was the The Tower in the naval base, the MoD’s headquarters on the Rock, and claimed local police had seized computer and telephone equipment.A Government in London said: “We can confirm three service personnel have been released on bail, as this is an ongoing investigation, we cannot comment further at this stage.“We reaffirm the strong and enduring relationship between the UK and Gibraltar.” Three senior British military officials have been arrested by Gibraltar police on suspicion of trying to hinder a child sex abuse inquiry, in a diplomatic row over who investigates crimes in the territory.The officials were held on suspicion of trying to pervert the course of justice before being bailed, after local police said they had been stopped from investigating another UK serviceman over alleged offences involving indecent images of children.The arrests on Wednesday followed a dramatic runway standoff last month when police officers blocked the departure of an A400M RAF military transport believed to be flying the serviceman back to the UK.