A man who stabbed his friend to death after a row over a piece of cannabis has been jailed for life.
The judge told the court the attack was "violent and frenzied"
The body of Sean Steedman, 37, was found in his Edinburgh home in July after friends climbed up to his window and saw him lying in a pool of blood.
At the High Court in Edinburgh, Alexander Barclay, 45, admitted the murder of Mr Steedman.
The judge, Lord Brailsford, said Barclay must serve at least 12 years before he can apply for parole.
The victim had received a dozen stab wounds to his chest.
Lord Brailsford said: "The stab wounds showed this was a frenzied and violent attack."
Advocate depute Angela Grahame, prosecuting, said both men had alcohol problems and used to drink together.
The court heard how Mr Steedman of Calder Drive, Edinburgh, was in Barclay's flat in the same street, on 11 July, with others, drinking and smoking cannabis.
After a row about a piece of cannabis Barclay was left alone in his flat.
Ms Grahame said he arrived at his nephew's home in the early hours of the morning and announced: "I have just murdered somebody."
Barclay dumped the blood-stained clothing in a rubbish chute and threw his knife into the Union Canal but later that day broke down and told his girlfriend, Moira Meldrum, he thought he had murdered someone.
She went to Mr Steedman's home to find anxious friends were already trying to find out what had happened to him.
When Ms Meldrum brought the news back to Barclay he said: "Oh my God, what have I done? That's my pal."
He then handed himself in to police.
Solicitor advocate Ray Megson, defending, said Barclay was an alcoholic who also dabbled in amphetamine, heroin, crack cocaine and cannabis.
The lawyer said that on the day of the murder he had been drinking since 0900 BST and said the events of that day were still "a bit of a blur".
He added that Barclay regarded Mr Steedman as one of his best friends.
Lord Brailsford said it was a warning to others to avoid abusing alcohol when it could lead to such events.