subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From danie...@apache.org
Subject svn commit: r1331125 - /subversion/trunk/subversion/libsvn_fs_fs/fs.c
Date Thu, 26 Apr 2012 22:04:35 GMT
Author: danielsh
Date: Thu Apr 26 22:04:34 2012
New Revision: 1331125

URL: http://svn.apache.org/viewvc?rev=1331125&view=rev
Log:
Follow-up to r1331050: try to unbreak the build.

* subversion/libsvn_fs_fs/fs.c
  (fs_hotcopy): Properly open SRC_FS.  Call svn_fs__check_fs(dst_fs).

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

Modified: subversion/trunk/subversion/libsvn_fs_fs/fs.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/fs.c?rev=1331125&r1=1331124&r2=1331125&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_fs/fs.c (original)
+++ subversion/trunk/subversion/libsvn_fs_fs/fs.c Thu Apr 26 22:04:34 2012
@@ -293,10 +293,34 @@ fs_hotcopy(svn_fs_t *src_fs,
            void *cancel_baton,
            apr_pool_t *pool)
 {
-  SVN_ERR(initialize_fs_struct(src_fs));
-  SVN_ERR(fs_serialized_init(src_fs, pool, pool));
-  SVN_ERR(initialize_fs_struct(dst_fs));
-  SVN_ERR(fs_serialized_init(dst_fs, pool, pool));
+    {
+      svn_fs_t *fs = src_fs;
+      const char *path = src_path;
+
+      SVN_ERR(svn_fs__check_fs(fs, FALSE));
+      SVN_ERR(initialize_fs_struct(fs));
+      SVN_ERR(svn_fs_fs__open(fs, path, pool));
+      SVN_ERR(svn_fs_fs__initialize_caches(fs, pool));
+      SVN_ERR(fs_serialized_init(fs, pool, pool));
+    }
+
+    {
+      svn_fs_t *fs = dst_fs;
+      const char *path = dst_path;
+
+      SVN_ERR(svn_fs__check_fs(fs, FALSE));
+      SVN_ERR(initialize_fs_struct(fs));
+#if 0 
+      /* In INCREMENTAL mode, svn_fs_fs__hotcopy() will open DST_FS.
+         Otherwise, it's not an FS yet --- possibly just an empty dir --- so
+         can't be opened.
+       */
+      SVN_ERR(svn_fs_fs__open(fs, path, pool));
+      SVN_ERR(svn_fs_fs__initialize_caches(fs, pool));
+#endif
+      SVN_ERR(fs_serialized_init(fs, pool, pool));
+    }
+
   return svn_fs_fs__hotcopy(src_fs, dst_fs, src_path, dst_path,
                             incremental, cancel_func, cancel_baton, pool);
 }



Mime
View raw message