fix for problem with writing utf-8 log on Windows