output size error cause crash bug fix