FreeBSD/contrib/subversion/subversion/libsvn_subr/cache-membuffer.c
/* If locking is supported for CACHE, acquire an unconditional write lock
 * for it.
 */
If locking is supported for CACHE, acquire an unconditional write lock
for it.
If locking is supported for CACHE acquire an unconditional write lock for it .
static svn_error_t *
force_write_lock_cache(svn_membuffer_t *cache)
{
#if (APR_HAS_THREADS && USE_SIMPLE_MUTEX)
  return svn_mutex__lock(cache->lock);
#elif (APR_HAS_THREADS && !USE_SIMPLE_MUTEX)
  apr_status_t status = apr_thread_rwlock_wrlock(cache->lock);
  if (status)
    return svn_error_wrap_apr(status,
                              _("Can't write-lock cache mutex"));
  return SVN_NO_ERROR;
#else
  return SVN_NO_ERROR;
#endif
}
static svn_error_t * force_write_lock_cache ( svn_membuffer_t * cache ) { #if ( APR_HAS_THREADS && USE_SIMPLE_MUTEX ) return svn_mutex__lock ( cache -> lock ) ; #elif ( APR_HAS_THREADS && ! USE_SIMPLE_MUTEX ) apr_status_t status = apr_thread_rwlock_wrlock ( cache -> lock ) ; if ( status ) return svn_error_wrap_apr ( status , _ ( " " ) ) ; return SVN_NO_ERROR ; #else return SVN_NO_ERROR ; #endif }
If locking is supported for CACHE, acquire an unconditional write lock
 for it.
If locking is supported for CACHE acquire an unconditional write lock for it .