PETALUMA (CBS SF) — A 21-year-old was hospitalized with life-threatening injuries and another man was in custody after a night of drinking in a Petaluma home ended with an accidental shooting, authorities said.

Petaluma police said they received a call at 11:50 p.m. Monday reporting a shooting inside a home in the 1400 block of Mountain View. The caller reported that he had “shot” his friend.

Arriving police and emergency medical personnel discovered a 21-year-old male victim, who was transported to Santa Rosa Memorial Hospital with life threatening injuries. He is expected to survive.

There were three residents inside the home and a visitor.

During the investigation it was determined that 21-year-old Petaluma resident William Gingras-McCauley was the shooter. He was detained at the scene and brought to police headquarters for questioning.

Gingras-McCauley admitted to accidentally discharging an SKS rifle, inadvertently striking the victim in the upper torso. He admitted that they had both consumed alcoholic beverages throughout the evening leading up to the shooting.

He was charged with negligent discharge of a firearm causing injury.

Anyone with information regarding this case is encouraged to contact Petaluma Police Detective John Silva at (707) 778-4532. For media inquiries please contact Sergeant Paul Gilman at (707) 778-4415.