The U.S. Court of Appeals for the Fifth Circuit has reversed a decision throwing out a Texas prisoner’s life sentence, which a judge below based on the fact that his lawyer failed to ask a jury to consider a manslaughter conviction carrying a maximum 20-year sentence.

Mejia v. Davis involves David Mejia, who was found guilty of murder for stabbing Marcos Torres outside a Victoria bar in 1998. Mejia’s trial attorney, Alex Luna, presented a self-defense theory based on Mejia’s claim that Torres was threatening him with a gun.