I'm fresh user of log4cxx. Recently one of the larger projects
in firm landed into my lap which uses log4cxx extensively, and
crashes on customer site (our internal testing newer caught this :()
due to following:
I have a class which has private log4cxx::LoggerPtr.
In constructor it is initialized like:
MyClass()
: logger(log4cxx::Logger::getLogger("someName"))
{
...
}
Then it is used extensively in some other parts of code and in
destructor it is set to NULL.
Program crashes because at some point logger becomes NULL, actually
operator-> method called on logger returns NULL. Since LOG4CXX_DEBUG
macro does logger->isDebugEnabled() this crashes due to NULL pointer
exception.
My question is which method called external to my class can make logger
(actually its underlying pointer) become NULL?
I hope I managed to explain my problem, any help is appreciated.
Thanks in advance,
--
Tomy <[EMAIL PROTECTED]>