logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Zhou Tao <zhoutao...@gmail.com>
Subject Re: LOG4CXX_DECODE_CHAR Crash on windows
Date Wed, 18 Nov 2009 05:12:15 GMT
Thanks Curt,

My comments in line.
*2009/11/18 Curt Arnold <carnold@apache.org>
> *Mismatching run-time libraries is a easy way to manufacture a crash.
> Basically any time one DLL tries to deallocate some resource allocated by a
> DLL using a different run time library (and that includes two DLLs that each
> use /MT since they have the own instances of the run-time library), bad
> things will happen.*

Tom>> Yes, it's the problem.

> *To build a DLL using the /MT run-time library and log4cxx, add the
> log4cxx source into your project and set the LOG4CXX_STATIC environment
> variable.  If you try linking with a static library, you will only get the
> classes that you call directly.  The ones that are expected to be present
> when the configuration is read will not have been linked into your DLL.*

Tom>> Do you mean to build the log4cxx source into my DLL?
My context is to build the log4cxx to a DLL and the log4cxx DLL would be
called in my DLL( build with /MT option). Mostly I cannot combine the
log4cxx code with my DLL code together. I maybe misunderstand you about your
way to handle the issue.


Thanks and Regards,

View raw message