Fixed: Completely broken code on POSIX using Unicode (UTF-8).