Fix crash caused by zero-sum block weights