U.S. President Barack Obama returns via the Marine One helicopter to the White House in Washington, U.S. June 2, 2016. REUTERS/Jonathan Ernst

WASHINGTON (Reuters) - U.S. President Barack Obama commuted the prison terms of 42 non-violent drug offenders, nearly half of whom were serving life sentences, in his latest batch of clemency decisions, the White House said on Friday.

The individuals “have more than repaid their debt to society and earned this second chance,” Neil Eggleston, the White House counsel, wrote in a blog. They were convicted under drug sentencing laws put on the books before Obama became president that were “outdated and unduly harsh,” Eggleston wrote.

Obama has worked to reform the U.S. criminal justice system to reduce the number of people serving long sentences for drug crimes. It is one of the few areas in which the Democratic president has received support from Republican lawmakers.

Many of the convicts had been serving time for crack cocaine charges. Crack offenders have for years faced stiffer penalties than offenders of powder cocaine, even though the two substances are molecularly similar. Critics have said the disparity has unfairly hurt minority communities.

Obama announced the most ambitious clemency program in 40 years in April, 2014. The program has struggled under a deluge of thousands of unprocessed cases.

Some legal experts, including Rachel Barkow, faculty director at the Center on the Administration of Criminal Law at New York University, have urged Obama to move faster on the program, saying unless he does, the program will remain a “lottery” for thousands of other convicts.

Friday’s commutations bring the total to 348, more than granted by the previous seven presidents combined, the White House said. George W. Bush commuted the sentences of 11 individuals, Bill Clinton granted clemency to 61 and George H.W. Bush granted clemency to three people, the White House said.

“We are confident that there will be many more commutations in the months” before Obama leaves office in January next year, Sally Yates, the deputy attorney general, said in a release.

The White House also said Obama is committed to strengthening drug rehabilitation programs.