A federal judge in New York on Friday cut the prison sentence of Jeffrey Skilling, former CEO of energy giant Enron, from 24 years to 14 years, meaning he could be free by 2020, according to Reuters.

U.S. District Judge Simeon Lake accepted a deal between prosecutors and Skilling’s lawyers, ending years of appeals from Skilling, who has maintained that he did nothing wrong at Enron.

Skilling’s resentencing has been in the works since 2009, after an appeals court held that Lake wrongly added more years to Skilling’s sentence than was warranted.

Skilling was convicted in 2006 and has been in prison since then.

About $41 million of Skilling’s money will be distributed to victims of Enron’s legendary collapse in 2001, AP reports.

Former Enron employees have widely criticized Skilling for denying any wrongdoing. The energy company’s fall in 2001 left more than 5,000 people unemployed, destroyed $2 billion in employee pensions, and wiped out $60 billion of Enron stock.

Skilling was convicted of conspiracy, securities fraud, insider trading and lying to auditors in 2006. He declined to comment during the court proceedings.

Even with the sentence reduction, his prison term is the longest of any involved in the Enron scandal. He could be free by 2020.