Hi, I'd just like to note that the LOG4CXX_ASSERT macro might be a bit
dangerous because of its usage of the "condition" param:
#define LOG4CXX_ASSERT(logger, condition, message) { \
if (!condition && logger->isErrorEnabled()) {\
logger->forcedLog(::log4cxx::Level::getError(), message,
LOG4CXX_LOCATION); }}
when used e.g. as LOG4CXX_ASSERT(lmain, false || true, "damn"), it
producess the error message when it shouldn't.
FIX: use parentheses
#define LOG4CXX_ASSERT(logger, condition, message) { \
if (!(condition) && logger->isErrorEnabled()) {\
logger->forcedLog(::log4cxx::Level::getError(), message,
LOG4CXX_LOCATION); }}
cheers,
Ondrej