subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stef...@apache.org
Subject svn commit: r1126005 - /subversion/trunk/subversion/libsvn_fs_fs/caching.c
Date Sun, 22 May 2011 15:52:39 GMT
Author: stefan2
Date: Sun May 22 15:52:39 2011
New Revision: 1126005

URL: http://svn.apache.org/viewvc?rev=1126005&view=rev
Log:
Follow-up to r1125729: Fix a compiler warning and check the
"cache fulltexts" flag instead of "cache txdeltas" to enable
fulltext caching.

* subversion/libsvn_fs_fs/caching.c
  (svn_fs_fs__initialize_caches): fix copy'n'pasto

Found by: ivan

Modified:
    subversion/trunk/subversion/libsvn_fs_fs/caching.c

Modified: subversion/trunk/subversion/libsvn_fs_fs/caching.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/caching.c?rev=1126005&r1=1126004&r2=1126005&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_fs/caching.c (original)
+++ subversion/trunk/subversion/libsvn_fs_fs/caching.c Sun May 22 15:52:39 2011
@@ -304,29 +304,31 @@ svn_fs_fs__initialize_caches(svn_fs_t *f
 
   /* initialize fulltext cache as configured */
   ffd->fulltext_cache = NULL;
-  if (cache_txdeltas)
-    if (memcache)
-      {
-        SVN_ERR(svn_cache__create_memcache(&(ffd->fulltext_cache),
-                                           memcache,
-                                           /* Values are svn_string_t */
-                                           NULL, NULL,
-                                           APR_HASH_KEY_STRING,
-                                           apr_pstrcat(pool, prefix, "TEXT",
-                                                       (char *)NULL),
-                                           fs->pool));
-      }
-    else if (svn_cache__get_global_membuffer_cache())
-      {
-        SVN_ERR(svn_cache__create_membuffer_cache(&(ffd->fulltext_cache),
-                                                  svn_cache__get_global_membuffer_cache(),
-                                                  /* Values are svn_string_t */
-                                                  NULL, NULL,
-                                                  APR_HASH_KEY_STRING,
-                                                  apr_pstrcat(pool, prefix, "TEXT",
-                                                              (char *)NULL),
-                                                  fs->pool));
-      }
+  if (cache_fulltexts)
+    {
+      if (memcache)
+        {
+          SVN_ERR(svn_cache__create_memcache(&(ffd->fulltext_cache),
+                                            memcache,
+                                            /* Values are svn_string_t */
+                                            NULL, NULL,
+                                            APR_HASH_KEY_STRING,
+                                            apr_pstrcat(pool, prefix, "TEXT",
+                                                        (char *)NULL),
+                                            fs->pool));
+        }
+      else if (svn_cache__get_global_membuffer_cache())
+        {
+          SVN_ERR(svn_cache__create_membuffer_cache(&(ffd->fulltext_cache),
+                                                    svn_cache__get_global_membuffer_cache(),
+                                                    /* Values are svn_string_t */
+                                                    NULL, NULL,
+                                                    APR_HASH_KEY_STRING,
+                                                    apr_pstrcat(pool, prefix, "TEXT",
+                                                                (char *)NULL),
+                                                    fs->pool));
+        }
+    }
 
   SVN_ERR(init_callbacks(ffd->fulltext_cache, fs, no_handler, pool));
 



Mime
View raw message