fixed illegal character exception