Malaysian Prime Minister Mahathir Mohamad on Tuesday came to the defence of a man facing the death penalty for selling cannabis oil to patients, saying his sentence should be reviewed.

Muhammad Lukman Mohamad, a 29-year-old father of one, was convicted of trafficking in cannabis, a crime punishable by death in Malaysia. He was sentenced to death by hanging on Aug. 30 and has filed an appeal, his lawyer, Farhan Maaruf, told Reuters.

During the trial, Muhammad Lukman testified that he had only sold cannabis oil to help patients suffering from illnesses such as cancer and leukemia, Farhan said.

The case sparked a debate over the use of marijuana for medical purposes, with many, including some lawmakers, calling for amendments to the country's harsh drug laws.

A Change.org petition, which urged the attorney-general to free Muhammad Lukman, has garnered nearly 45,000 signatures.

Asked about the case, Mahathir told reporters it should be reviewed.

"No, I think we should review that," he was quoted as saying in a video recording of his comments seen by Reuters.

Nurul Izzah Anwar, a member of parliament from Mahathir's coalition, said she would be writing a letter calling for the attorney-general to reconsider the conviction and penalty for Muhammad Lukman.

"From the reports, it looks to be a miscarriage of justice," she said.

The attorney-general's office did not immediately respond to a request for comments.

Malaysia, like other countries in Southeast Asia, imposes harsh penalties for drug offences. Last year, parliament voted to remove the death penalty as mandatory punishment for drug trafficking and leave it to the judges' discretion instead.

Earlier this year, an Australian mother of three was sentenced to death for trafficking more than a kilogram of crystal methamphetamine into Malaysia.