Image copyright AFP Image caption Indonesian troops were waiting for the plane after the pilot reported a possible hijacking while in the air

A passenger who caused a hijack scare on a flight from Australia to Indonesia has been arrested at Bali airport, officials say.

Virgin Australia said a passenger had been handcuffed by crew on the Boeing 737 after acting aggressively.

The flight from Brisbane was boarded by Indonesian troops on landing after reports that it had been hijacked.

Virgin blamed confusion around the incident on a "miscommunication" and said the passenger had been drunk.

The BBC's Karishma Vaswani in Indonesia said fears of a hijacking were caused after the pilot sent a distress signal to airport authorities.

"This is no hijacking, this is a miscommunication," Heru Sudjatmiko, a Virgin Australia official said.

"There was a drunk passenger, intoxicated and aggressively behaved. He was trying to enter the cockpit, banging the door but he did not enter the cockpit."

Crew members seized the passenger, who authorities identified as Matt Christopher Lockley, a 28-year-old from Australia.

Image copyright AFP Image caption Passengers on nearby aircraft saw the drama unfold and took photographs of the plane

An hour before landing in Bali, the plane's original destination, the pilot alerted traffic controllers to a possible hijacking on board, an Indonesian air force spokesman said.

Palani Mohan, a passenger on another flight that was about to take off from Bali, told AFP that the pilot of his plane announced the airport was in lockdown.

"The captain of my plane made an announcement saying we were delayed indefinitely because a hijack was going on in Bali airport, about 150 metres away from us."

"I saw at least five vehicles including military-style trucks, filled with men in uniform, rushing towards the plane," he said.

"Then the Virgin plane taxied away, followed by the convoy of security forces."

Police arrested the man shortly after the plane landed and all of the passengers were unharmed.

The airport was closed briefly but flights resumed shortly after the incident.

Virgin Australia Airlines, formerly Virgin Blue Airlines, is Australia's second-largest airline.