Dr Gibb had conditions imposed on his licence to practise
A doctor caught with 14 ecstasy tablets at a music festival has been allowed to keep his licence to practise.
A General Medical Council panel told Dr Fraser Gibb they were satisfied he only used drugs to enhance his life and not to "prop it up".
However, it found him guilty of misconduct and imposed conditions on his licence over the next 18 months.
Dr Gibb, 41, of Steilston, Dumfries, was convicted of possessing the drug at the Wickerman Festival in July 2006.
Police also discovered small amounts of amphetamine and cannabis resin when they searched his vehicle.
All the drugs were contained in his glasses case on the back seat.
He was convicted at Kirkcudbright Sheriff Court and fined £400.
The fitness to practise panel, sitting in Manchester, found Dr Gibb guilty of misconduct and imposed a number of conditions on his licence for the next 18 months.
Among the conditions are that he does not possess illegal drugs, except in the discharge of his clinical duties, and he must be supervised at all times.
The panel stated it was satisfied that since the incident he had shown remorse for his conduct.
"During your evidence you described your behaviour as foolish and said that you used drugs to enhance your life, not to prop it up.
"The panel is further satisfied that there is not a significant risk of such behaviour recurring."
The panel also concluded Dr Gibb did not give false personal details when questioned by officers at the festival.
The hearing was told Dr Gibb had not taken illicit drugs since the event, which was supported by toxicology screening and blood tests, and had since set aside his "ill-judged lifestyle choice".
Colleagues at Dumfries and Galloway NHS Trust said the locum consultant psychiatrist at Crichton Royal Hospital was an asset to the trust and preventing him from working would not serve any purpose for patients.