On Apr 8, 2009, at 4:17 AM, Lijuan Zhu wrote:
I am new to Log4cxx, and just got it into my projects. I have two
questions now:
1, The log file I specified in the xml configuration file should
exist? how to change the configuration so the log4cxx could create
the log file if it does not exist?
2. I could not log Chinese characters into the log file (there are
something like this:2009-04-08 10:02:29,68? ERROR [ps.?f]??????), is
there any setting I can change to make it show the logs correctly?
Thanks a lot,
Lijuan
Check the mailing list archive for more detail (search for locale and/
or encoding). You likely also need to make a call to setlocale,
ideally called before your first log statement which will tell the run-
time what encoding it should use to interpret char*. Without a call
to setlocale(), the default is the USASCII.