STUDIO CITY (CBSLA) — The man charged in the deadly shooting of a beloved Long Beach firefighter has died in police custody.

Thomas Kim died Sunday of a “pre-existing medical condition,” the Los Angeles County Sheriff’s Dept. said.

The 77-year-old had been accused of killing Long Beach Fire Dept. Capt. David Rosa in the early morning of June 25. Rosa had responded to reports of an explosion around 3:40 a.m. at the Covenant Manor senior living facility.

As Rosa was searching for possible victims of the firebombing, Kim fatally shot the 17-year LBFD veteran. Another firefighter, Ernesto Torres, was grazed by a bullet, and a resident of the building was also shot; neither injury was life-threatening.

It was later revealed Kim set a gasoline fire to kill himself and an upstairs neighbor with whom he had been having a dispute.

LBFD issued the following statement on Kim’s death:

“Although we are devastated that this man will never stand trial for the murder that he committed, our focus remains on protecting the Rosa family and the memory of the many honorable and moving contributions that Captain Rosa made to his family and the community.”

Others were more blunt, however.

“I think he go what he deserved,” Covenant resident Noreen Convay told CBS2 News. “I feel better that it’s over. There’s a closure, not with many, but us. I mean, it’ll always be a reminder.”

Neighbors said Kim was being treated for cancer and a kidney disorder.

Thomas Kim appeared frail during a court appearance. (credit: CBS2)

Kim was charged with capital murder, attempted murder and arson, and he did not enter a plea when he first appeared in court.

Rosa is survived by his wife and two children.

(© Copyright 2018 CBS Broadcasting Inc. All Rights Reserved. City News Service contributed to this report.)