restore char code