Honestly, it's probably worth it to read far more of God in the Dock: Essays on Theology than that one quote. For instance, to mine nothing more than other parts of the same paragraph:
If the justification of exemplary punishment is not to be based on desert but solely on its efficacy as a deterrent, it is not absolutely necessary that the man we punish should even have committed the crime. The deterrent effect demands that the public should draw the moral, 'If we do such an act we shall suffer like that man.' The punishment of a man actually guilty whom the public think innocent will not have the desired effect; the punishment of a man actually innocent will, provided the public think him guilty. But every modern State has powers which make it easy to fake a trial. When a victim is urgently needed for exemplary purposes and a guilty victim cannot be found, all the purposes of deterrence will be equally served by the punishment (call it 'cure' if you prefer) of an innocent victim, provided that the public can be cheated into thinking him guilty. It is no use to ask me why I assume that our rulers will be so wicked. The punishment of an innocent, that is, an undeserving, man is wicked only if we grant the traditional view that righteous punishment means deserved punishment. Once we have abandoned that criterion, all punishments have to be justified, if at all, on other grounds that have nothing to do with desert. Where the punishment of the innocent can be justified on those grounds (and it could in some cases be justified as a deterrent) it will be no less moral than any other punishment.
and
To be 'cured' against one's will and cured of states which we may not regard as disease is to be put on a level with those who have not yet reached the age of reason or those who never will; to be classed with infants, imbeciles, and domestic animals. But to be punished, however severely, because we have deserved it, because we 'ought to have known better', is to be treated as a human person made in God's image.
Honestly, it's probably worth it to read far more of God in the Dock: Essays on Theology than that one quote. For instance, to mine nothing more than other parts of the same paragraph:
and