dont do substr_offset on invalid length fields