Non-English logging

When logging messages in languages other than English, you may need to set your locale correctly for messages to be displayed.

For example, here is some Hebrew text which says “People with disabilities”:

אנשים עם מוגבלות

If you are to log this information on a system with a locale of en_US.UTF-8, the log message will look something like the following:

loggername - ?????????? ???? ??????????????

One way to fix this is to call setlocale as follows before the function that logs:

std::setlocale( LC_ALL, "" );

This will then allow the message to be logged appropriately.

See issue LOG4CXX-483 for more information.