The answer might depend on the nature of the crime, the length of the sentence, and the proportion of it that remains to be served. For a pickpocket who has served half of a two-year sentence, it would be excessively harsh to insist on the sentence being served in full if that meant that he would die in prison, rather than with his family.