A DUNFERMLINE offender who was twice given the chance to avoid jail but breached court orders is now behind bars.

Robert McGarry had originally been given a community payback order but only completed five hours out of the 240-hour sentence.

All he did was attend the induction and did not carry out any actual work, Dunfermline Sheriff Court was told.

That order was revoked and in its place, McGarry was put on a drug treatment and testing order which was another flop as far as his participation was concerned.

McGarry, 36, of Dunn Crescent, Dunfermline, has now been jailed for 460 days for a string of offences previously admitted.

On February 13, at an address in Abel Place, Dunfermline, he behaved in a threatening or abusive manner by shouting, swearing and repeatedly banging on the door.

On the same day at Dunn Crescent, he made phone calls of a grossly offensive or of an indecent, obscene or menacing character and was shouting and swearing.

He also admitted that, at Abel Place, he was in possession of cannabis resin.

Depute fiscal Jennifer Graham said McGarry’s offending that day started at 5.30am when he began banging at a door of a home shouting “Let me f****** in”.

Then at 9.30am, he made a threatening call to the same house, saying to his daughter he would put a hammer through the window to get in.

Police were called and they found a backpack which McGarry had left lying when he was at Abel Place. It was found to contain 77 grams of cannabis resin, with a value of around £350.

McGarry was also being sentenced for a violent assault.

On September 10, 2016, at an address in Mackie Place, he assaulted a male by punching him to the head and body and kicked him to the body to his injury.

Defence solicitor Russel McPhate said this had been in response to an allegation of rape and his client became frustrated nothing was being done about it.