1st of all, he had no gun, he said he had a bomb (hint: he didn't). He was addicted to pills, and in my opinion jail isn't the place for people who need help. It can be your opinion that he deserves to go to jail and that is fine. To me, he needs help with his addiction and treatment of his cancer...not sitting in a jail cell with murderers and rapists.
Had this not been a one time thing, and if he had priors, then perhaps I would be more inclined to think he deserves to be in jail. As it stands on the facts of this case, I don't believe jail was the right option, and apparently the court didn't either.