[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Subversion BDB doesn't work with Apache 2.4 event MPM

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 05 Apr 2012 11:45:57 +0100

Branko Čibej <brane_at_apache.org> writes:

>> ... I think I may have identified the problem. The patch below checks
>> that the error struct is allocated and released by the same thread.
>> With the worker MPM the assertion always passes but with the event MPM I
>> get assertion failures. I don't fully understand the effect this would
>> have but I suspect it explains the problem.
>
> I think this pretty much explains what you're seeing.

Yes. Thread A allocates the memory, stores the address in the
thread-specific data, sets the refcount to one and sets up the pool
cleanup handler. Thread A finishes with the request. Thread B runs the
pool cleanup handler, sets the refcount to zero, frees the memory and
sets the *wrong* thread-specific data to NULL. Thread A then gets the
free'd address from the thread-specific data and continues to use
it--all sorts of horrible things follow.

I've raised issue 4157 to track this problem.

-- 
uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com
Received on 2012-04-05 12:46:37 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.