Glee actor Mark Salling was found dead near Los Angeles weeks before he was scheduled to be sentenced for possessing a huge library of child porn, his attorney confirmed. He was 35.

The cause of death was not immediately released, but a law enforcement official who was not authorized to speak publicly told the Associated Press that Salling was found hanging in a riverbed area.

LA police confirmed that officers responded to scene near the foothill community of Sunland at 8:50 a.m. Tuesday, where they found the body. He had been reported missing hours earlier.

Salling, who played Noah Puckerman on Glee, admitted in October to using software to mask his IP address and download thousands of images of child pornography, which investigators found in 2015 after acting on a tip, reportedly from a woman who was shown the content multiple times.

According to the plea agreement, more than 50,000 images and hundreds of videos of child pornography were found on Salling’s laptop and his thumb drive. Some of the female victims were as young as 3 to 5 years old, federal prosecutors said.

A judge was scheduled to review a deal he signed in exchange for pleading guilty to child porn charges. He was expected to be sentenced in March to four to seven years in prison, and be ordered to register as a sex offender. He also agreed to pay $50,000 to each victim who submitted a formal restitution request, and to spend 20 years under supervised release.

Salling was initially arrested by LA police on Dec. 29, 2015, and released on bond. However, once investigators realized the scope of the child pornography, the matter was referred to federal authorities. He was indicted on two counts of receiving and possessing child pornography and pled not guilty to the charges in June 2016.