Fixed a bug due to 'unicode'

ValueError: All strings must be XML compatible: Unicode or ASCII, no
NULL bytes or control characters