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

fsfs's fs_serialized_init() not thread safe?

From: Blair Zajac <blair_at_orcaware.com>
Date: Sun, 09 Jan 2011 12:09:34 -0800

Wanted to confirm a reading of fs_serialized_init() in libsvn_fs_fs/fs.c in a
persistent, multithreaded server.

It appears that if fs_serialized_init() is called at the same time by two or
more threads, then you would have a race on apr_pool_userdata_get() and
apr_pool_userdata_set().

It looks like a good fix for this would be to have svn_fs_initialize() call down
into the fs implementation library to set this up? Would that be a good
solution to this? It would need to call into all fs implementation libraries
though, loading a .so that may never be used.

Blair
Received on 2011-01-09 21:10:12 CET

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.