fix character decode