Fix for utf-8 encoding

Special characters were fouling up the read/write streams in the Critic
preprocessor. Now working with the codecs module.