Em 04/07/2013 18:29, Pedro Lamarão escreveu:

> I am seeing a crash in Logger::~Logger with the stack as below [1].
> 
> My loggers are instantiated at static initialization time, with
> variables in namespace scope like this:
> 
> namespace x { Logger logger = LogManager::getLogger("x"); }
> 
> At the crash point in apr_pool_cleanup_kill the (apr_pool_t *) variable
> has value 0xfeeefeee suggesting this is a double-free of some kind.

We have determined in our scenario that the static finalization of
"logger" (as above) happens after the static finalization of "selector"
defined in LogManager::getRepositorySelector.

Finalization of "selector" causes destruction of Hierarchy which in turn
causes delete of "loggers".

It seems this is a double-free of the Logger itself, that is, it seems
that static finalization is entering ~Logger for the second time.


Pedro Lamarão Rosa e Silva
Prodist Technologies
http://www.prodist.com.br/
"Securing Transaction Systems"
Tel.: (21) 4062-7188

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to