stef...@apache.org wrote on Fri, Jul 01, 2011 at 08:34:20 -0000:
> Author: stefan2
> Date: Fri Jul  1 08:34:20 2011
> New Revision: 1141868
> 
> URL: http://svn.apache.org/viewvc?rev=1141868&view=rev
> Log:
> On the svn_mutex branch, add a readme as requested.
> 
> * BRANCH-README: new file
> 
> Added:
>     subversion/branches/svn_mutex/BRANCH-README
> 
> Added: subversion/branches/svn_mutex/BRANCH-README
> URL: 
> http://svn.apache.org/viewvc/subversion/branches/svn_mutex/BRANCH-README?rev=1141868&view=auto
> ==============================================================================
> --- subversion/branches/svn_mutex/BRANCH-README (added)
> +++ subversion/branches/svn_mutex/BRANCH-README Fri Jul  1 08:34:20 2011
> @@ -0,0 +1,19 @@
> +svn_mutex__t is supposed to be an almost zero-overhead
> +wrapper around apr_thread_mutex_t. And if it wasn't for
> +the 1.7 stabilization, this change would be developed
> +directly on /trunk.
> +
> +The basic idea is to move code patterns like
> +
> +#if APR_HAS_THREADS
> +  if (my_struct->mutex)
> +    {
> +      status = apr_thread_mutex_lock(my_struct->mutex);
> +      if (status)
> +        return svn_error_wrap_apr(...)
> +    }
> +#endif
> +
> +into a dedicated function such that callers may simply do
> +
> +  SVN_ERR(svn_mutex__lock(my_struct->mutex));

SVN_ERR(svn_mutex__with_lock(&mystruct->mutex, my_callback));

?


> 
> 

Reply via email to