This added check is actually for NOT failing in NON-strict mode. The ch == -2 check later causes the desired failure in strict mode.