You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2011/02/20 09:30:51 UTC
svn commit: r1072528 -
/subversion/trunk/subversion/libsvn_subr/cache-membuffer.c
Author: stefan2
Date: Sun Feb 20 08:30:51 2011
New Revision: 1072528
URL: http://svn.apache.org/viewvc?rev=1072528&view=rev
Log:
Fix cache item acceptance check to actually set the limit at
1/4th of the cache segment size.
* subversion/libsvn_subr/cache-membuffer.c
(svn_membuffer_cache_is_cachable): remove extra divisor
as we "cache" is actually a single segment already.
Modified:
subversion/trunk/subversion/libsvn_subr/cache-membuffer.c
Modified: subversion/trunk/subversion/libsvn_subr/cache-membuffer.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/cache-membuffer.c?rev=1072528&r1=1072527&r2=1072528&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/cache-membuffer.c (original)
+++ subversion/trunk/subversion/libsvn_subr/cache-membuffer.c Sun Feb 20 08:30:51 2011
@@ -1258,7 +1258,7 @@ svn_membuffer_cache_is_cachable(void *ca
* must be small enough to be stored in a 32 bit value.
*/
svn_membuffer_cache_t *cache = cache_void;
- return (size < cache->membuffer->data_size / 4 / CACHE_SEGMENTS)
+ return (size < cache->membuffer->data_size / 4)
&& (size < APR_UINT32_MAX - ITEM_ALIGNMENT);
}