fix for invalid byte sequence in US-ASCII error