Hi,
I am using v1.2.10 and having issues with Korean and Chinese locales. I am 
using XmlLayout and in the XML log file, messages (contents of the element 
"message") in Korean and Chinese languages appear as "????". I am using the 
correct encoding "utf-8", however I tried with other possible encodings 
supporting Unicode but the problem did not get solved.

I debugged the code and found that in Transform class, MaskXmlInvalidCharacters 
function escapes the valid Korean and Chinese characters as "?" characters 
because it thinks they are invalid XML unicode characters, its basically the 
following array defined in Transform class which is creating the problem:

private static Regex INVALIDCHARS=new 
Regex(@"[^\x09\x0A\x0D\x20-\xFF\u00FF-\u07FF\uE000-\uFFFD]",RegexOptions.Compiled);

Could anybody suggest a possible workaround for this? If I bypass the masking 
step, the message appears correctly in the log file. Or, is this a bug which 
should be solved in a certain manner?

One more issue that I am facing is that we had included the log4net dll long 
time back in our sources as a reference.
Now, if I try to rebuild the dll from the log4net sources and try replacing it 
with the older dll, our sources doesn't get built and the following compiler 
error is thrown:

Error     796       Unknown build error, 'The located assembly's manifest 
definition does not match the assembly reference. (Exception from HRESULT: 
0x80131040)'

I have tried the following things:
1.Building log4net sources with VS2005 and keeping the conditional compilation 
sysmbols as NET;NET_2_0 as well as NET;NET_1_0
2.Building log4net sources with VS2008 and keeping the target framework as 3.5
But nothing seems to work.

The old log4net dll seems to have been built on VS2005 with conditional 
compilation sysmbols as NET;NET_2_0 and our sources are built using VS 2008 
using target framework as 3.5.

What is it that I might be doing wrong? Initially I was getting errors related 
to strong names but I resolved it by generating the .snk file as mentioned on 
the Apache website and signing the dll.

Please help.

Regards,
Mayank







Reply via email to