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

Re: svn commit: r18260 - trunk/subversion/libsvn_ra_serf

From: Sander Striker <s.striker_at_striker.nl>
Date: 2006-01-27 22:01:06 CET

Greg Hudson wrote:
> On Fri, 2006-01-27 at 09:24 -0800, Justin Erenkrantz wrote:
>>The key for the subpool is to have serf's socket be in a separate pool
>>from the main session pool. Without that (i.e. everything in one
>>pool), the underlying socket gets cleared before the serf cleanup
>>routines are called and it leads to a segfault. Placing serf in its
>>own subpool resolves this problem.
> Two criticisms:
> * APR documents that cleanups are run in reverse order of
> registration, but I don't see any documentation that subpool cleanups
> will be run after pool cleanups.

And they're not. pool cleanups will be run after subpool cleanups.
The first thing that happens on apr_pool_clear() is destruction of
its subpools, only after that the pools cleanups are run.

Aparently this isn't obvious, so I guess I'll need to go and document

> So, unless I missed something, you seem to have resolved this problem
> by relying on undocumented behavior,
> when you could just register your cleanup after the socket is created
> and rely on documented behavior.


To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Jan 27 22:06:35 2006

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.