am-c-p-p commented on a change in pull request #728: MINIFICPP-1147 Implemented. URL: https://github.com/apache/nifi-minifi-cpp/pull/728#discussion_r376595029 ########## File path: extensions/windows-event-log/ConsumeWindowsEventLog.cpp ########## @@ -226,20 +229,32 @@ void ConsumeWindowsEventLog::onSchedule(const std::shared_ptrgetProperty(OutputFormat.getName(), mode); + + writeXML_ = (mode == Both || mode == XML); + + writePlainText_ = (mode == Both || mode == Plaintext); + + if (writeXML_) { + char systemDir[MAX_PATH]; + if (GetSystemDirectory(systemDir, sizeof(systemDir))) { Review comment: It is not necessary since minificpp uses Multi-Byte Character Set and macro GetSystemDirectory resolved as GetSystemDirectoryA. In general, if a concern that there is a possibility to accidentally use Unicode instead of Multi-Byte Character Set (or vice versa) - it is not possible because of compilation error. This is a common way to use any Windows API without specifying 'A' or 'W', for instance GetSystemDirectory usage in chromium: https://chromium.googlesource.com/chromium/src/base/+/refs/heads/master/base_paths_win.cc We should use Windows API this way as well. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services