Fixed a bug in unicode conversion in the scanner.