Fix serious bug in 08e17b322e5f00c24ead309595809c7bd3913744