A man has been locked up for three-and-a-half years for setting fire to a flat where his three friends were sleeping.

John Tretton, 47, stormed around to Owen Neilson's home at midnight and pushed lighted paper through the letterbox, Bradford Crown Court heard on Monday.

The carpet in the Aire-Wharfe Community Housing Trust property, in Parkwood Rise, Keighley, caught fire, endangering the lives of Mr Neilson, Karen Wilson and her aunt, Bernadette Wilson.

Mr Neilson woke and put out the flames, prosecutor Andrew Kershaw told the court.

Tretton, who was homeless at the time, pleaded guilty to arson being reckless as to whether the lives of the three were endangered.

Mr Kershaw said Mr Neilson had shown Tretton kindness by letting him stay at his flat.

But he felt he was being taken advantage of and had asked him to leave. At about midnight, on September 29, last year, Tretton banged on the door after downing four litres of cider and shouted death threats. He was on bail for drunk and disorderly behaviour and criminal damage.The flat was 40 feet above ground with only one entrance, Mr Kershaw said.

Tretton then set the property on fire.

Miss Wilson, who had been drinking and had taken a sleeping pill, did not wake.

Tretton's barrister, Ken Green, said Tretton had become a chronic alcoholic since his mother died and was extremely remorseful for putting his friends at risk.

Damage was minor and no one was injured.

Jailing Tretton, Judge Roger Scott said that fire and anger were a potent mix. Many people had died when those angry and in drink had set fire to their homes.