The U.S. Supreme Court gave a Texas death rowinmate a chance to avoid execution on Wednesday, with Chief Justice John Roberts denouncing the "noxious strain of racial prejudice" that infected the case when a defense witness testified the man was more likely to commit future crimes because he is black.

The 6-2 ruling handed a victory to convicted murderer Duane Buck, 53, who had challenged his death sentence in a state that long has led the nation in executions, citing the racially biased testimony by a psychologist called by his own trial lawyer.

Win an iPhone 7 Sign up to our daily newsletter for your chance to win.

Your browser does not support iframes.

Buck's lawyers said the ruling, authored by the conservative Roberts, paved the way for either for a life sentence or a new sentencing hearing.

"Today's decision sends a powerful message that no court can turn a blind eye to racial bias in the administration of criminal justice," said Christina Swarns of the NAACP Legal Defense and Educational Fund, one of Buck's lawyers.

"Given the persistence of racialized fears, stereotypes, and discrimination, this decision is as important to the country as it is to Duane Buck," Swarns added.

Lead counsel Christina Swarns (C) for Texas death row inmate Duane Buck (not pictured) walks down the front steps of the U.S. Supreme Court in Washington, U.S. October 5, 2016. REUTERS/Gary CameronREUTERS/Gary Cameron

Buck was convicted of fatally shooting his former girlfriend while her young children watched, as well as another man, during a 1995 argument in Houston. A police officer testified that after being detained Buck laughed and said, "The bitch got what she deserved."

Clinical psychologist Walter Quijano testified as a defense witness during the sentencing phase of the trial on the key issue of Buck's likelihood of committing future offenses. Quijano said race was among the "statistical factors" he weighed in deciding whether a person posed an ongoing danger because it is "a sad commentary that minorities, Hispanics and black people, are over-represented in the criminal justice system."

A prosecutor then asked Quijano if he had determined that "the race factor, black, increases the future dangerousness for various complicated reasons." Quijano replied: "Yes."

Roberts wrote that Quijano's testimony was clearly prejudicial to Buck, even if it was only a small part of the proceeding.

"Some toxins are deadly in small doses," Roberts wrote, adding that the expert testimony "appealed to a powerful racial stereotype" of black men as violent predators.

Roberts said a lower court's refusal to allow Buck to challenge his sentence was "a disturbing departure from a basic premise of our criminal justice system: Our law punishes people for what they do, not who they are."

"Dispensing punishment on the basis of an immutable characteristic flatly contravenes this guiding principle," Roberts added.

The court found Buck's trial lawyer violated Buck's right under the U.S. Constitution to be represented by competent counsel. Buck's current lawyers said the supposed link between race and future dangerousness has been proven false.

Enduring Racial Bias

Death penalty opponents have pointed to statistics showing black defendants to be far more likely than white defendants to be sentenced to die, and argue that racial bias endures in the American criminal justice system and indeath penalty cases in particular.

Texas has executed more people than any other state since capital punishment was reinstated in the United States four decades ago, including two already this year.

"We are disappointed with the court's ruling, but await further proceedings," said Marc Rylander, a spokesman for Texas Attorney General Ken Paxton, a Republican.

Liberal justices in previous cases have said the death penalty may constitute unconstitutional cruel and unusual punishment but the high court has shown little appetite to tackle the issue of the constitutionality of capital punishment.

The chief justice's language on racial injustice was notable, in part because Roberts has a history of ruling against civil rights groups on issues such as racial preferences in university admissions and voting rights. But in individual cases, Roberts has called out racial injustice in criminal cases.

In May 2016, he wrote the opinion when the court threw out a black Georgiainmate's conviction for murdering a white woman, saying prosecutors unlawfully excluded black potential jurors in picking an all-white jury that condemned him to death.

In Wednesday's case, conservative justices Clarence Thomas, the court's only black member, and Samuel Alito dissented. In his dissent, Thomas said the ruling was limited to the facts in Buck's case and would have narrowimplications.

"Having settled on a desired outcome, the court bulldozes procedural obstacles and misapplies settled law to justify it," Thomas wrote.

Texas in 2002 allowed six other death row inmates convicted in trials in which Quijano gave similar testimony to get new sentencing hearings but objected in Buck's case.

All six of those prisoners were again sentenced to death. Three have been executed.