Court orders retrial of man on death row