SAN FRANCISCO-- A San Francisco sheriff's deputy has been ordered to give up his weapon after he accidentally fired a non-duty weapon inside a courthouse.

KNTV-TV reports that the deputy discharged the small non-duty Glock on Wednesday while he was showing a colleague how to properly use the weapon. No one was injured.

San Francisco Sheriff's Department spokeswoman Eileen Hirst says the discharge is under investigation. She says the deputy is still on duty but was disarmed pending the outcome.

Get Breaking News Delivered to Your Inbox

Officials say one deputy brought the 22-caliber handgun to work at the Hall of Justice and asked a colleague how to operate the weapon. That deputy didn't know the weapon was loaded and pulled the trigger.

The round lodged in a wall between the sheriff's office and court offices.