Nashville songwriter Richard Fagan has passed away, bringing to an end one of the strangest stories in country music history.

The 69-year-old country hitmaker died on Friday (Aug. 5) in hospice care after battling liver cancer, according to the Tennessean newspaper. In the course of a decades-long career, Fagan scored hits with artists including Moe Bandy, Shenandoah, Mel McDaniel and George Strait. He landed a No. 1 hit in "Sold (The Grundy County Auction Incident)", as performed by John Michael Montgomery. The singer also reached No. 1 with "Be My Baby Tonight," another of Fagan's songs.

But it was a darker chapter of Fagan's life that brought him the largest spotlight. In 2008, the songwriter made headlines when he was arrested and charged in the death of his best friend, Nashville music publisher Tom Oteri.

It was Oteri who originally brought Fagan to Nashville, according to Rolling Stone Country. The two men became friends in the mid-'70s after Fagan -- a Philadelphia native -- returned from serving in Vietnam. Oteri helped him put together the demo package that eventually resulted in Neil Diamond recording one of his songs, "The Good Lord Loves You," in 1980.

The Tennessean reports that Oteri -- who was the father of Saturday Night Live cast member Cheri Oteri -- took Fagan in when he came to Nashville in the '80s, helping him through problems with drugs and alcohol and championing his songs. The two lived in the same house, and it was there, in April of 2008, that the fight took place that would alter the paths of both men irrevocably.

Fagan told the Tennessean he had been mixing alcohol and antidepressants when he and Oteri got into an argument, which resulted in Oteri telling him to get out. Fagan recalled slashing Oteri's wrists with a pocket knife, getting in his car and driving away, but he did not intend to or believe he had killed his friend and mentor. He was arrested for DUI later that night, and after he was released, he was re-arrested and charged with criminal homicide after Oteri's body was found.

In a strange twist, Fagan was sentenced to rehab, not prison, by a judge after Oteri's children intervened. An autopsy concluded that Oteri died not from the cuts on his wrists, but of a heart attack, and the murder charges were dropped. Fagan spent months in rehab, and after his release he was determined to serve as a mentor to others in the songwriting community, in much the same way Oteri had done for him. His Facebook page is full of loving tributes from those who attest that he did just that in the ensuing years.

He remained haunted by guilt over Oteri's death. "It should have been me," he told the Tennessean while promoting his final solo album, the appropriately-titled Redemption, which was released in 2015. Fagan worked hard at various charity endeavors, too, all fueled by a desire to make a positive difference.

"I want to leave a bigger legacy," he said.

Fagan was diagnosed with liver cancer three-and-a-half years ago, and given just six months to live. Instead, he lived to make the final album that in so many ways defined his life and legacy.

"[He] was one of the most original and innovative songwriters to ever walk the streets of Nashville," Fagan's longtime friend, songwriter Kacey Jones, tells Rolling Stone Country. "A word-master, a melodic genius, and a natural comedian whose intelligent humorous songs would make you beg for mercy, he could also reach deep into your soul with his beautiful ballads. He was a spiritual man who meditated daily and treasured his wife and friends above all."

Fagan is survived by his wife, Rose. Funeral arrangements are pending.

More Country Greats Who've Died in 2016