You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ko...@apache.org on 2016/01/09 20:20:41 UTC

svn commit: r1723877 - in /subversion/branches/fs-node-api/subversion: include/ libsvn_fs/ libsvn_fs_fs/ libsvn_ra_local/ libsvn_repos/

Author: kotkov
Date: Sat Jan  9 19:20:41 2016
New Revision: 1723877

URL: http://svn.apache.org/viewvc?rev=1723877&view=rev
Log:
On 'fs-node-api' branch: Switch remaining parts of svn_ra_local__get_dir()
to the new FS node API.

* subversion/include/svn_fs.h
  (svn_fs_node_created_rev2): New, works with svn_fs_node_t instead of
   a svn_fs_root_t and a path.  Revved from this ...
  (svn_fs_node_created_rev): ...function.
  (svn_fs_node_proplist2): New, works with svn_fs_node_t instead of
   a svn_fs_root_t and a path.  Accepts two pools.  Revved from this ...
  (svn_fs_node_proplist): ...function.

* subversion/include/svn_repos.h
  (svn_repos_get_committed_info2): New, works with svn_fs_node_t instead of
   a svn_fs_root_t and a path.  Accepts two pools.  Revved from this ...
  (svn_repos_get_committed_info): ...function.

* subversion/libsvn_fs/fs-loader.h
  (struct node_vtable_t): Add new node_created_rev and node_proplist
   vtable members.

* subversion/libsvn_fs/fs-loader.c
  (svn_fs_node_created_rev2, svn_fs_node_proplist2): Implement these new
   functions; forward everything to corresponding vtable members.

* subversion/libsvn_fs/node_compat.c
  (compat_fs_node_created_rev, compat_fs_node_proplist): Implement these
   compatibility wrappers and add them into ...
  (compat_node_vtable): ...this vtable instance.

* subversion/libsvn_fs_fs/node.c
  (fs_node_created_rev, fs_node_proplist): Implement these new FSFS-specific
   functions.  Forward everything to the DAG layer, but without inducing an
   unnecessary DAG walk.  Add these functions into ...
  (fs_node_vtable): ...this vtable instance.

* subversion/libsvn_repos/rev_hunt.c
  (svn_repos_get_committed_info): Open an svn_fs_node_t and call ...
  (svn_repos_get_committed_info2): ...this new function.

* subversion/libsvn_ra_local/ra_plugin.c
  (get_node_props): Rework to accept an svn_fs_node_t instead of a
   svn_fs_root_t and a path.
  (svn_ra_local__get_file): Update, call get_node_props() and pass in an
   opened svn_fs_node_t.
  (svn_ra_local__get_dir): Update, call get_node_props() and pass in an
   opened svn_fs_node_t.  Use new svn_repos_get_committed_info2() function
   when handling specific dirent_fields.

* subversion/libsvn_repos/repos.c
  (svn_repos_stat): Use new svn_repos_get_committed_info2() function.

Modified:
    subversion/branches/fs-node-api/subversion/include/svn_fs.h
    subversion/branches/fs-node-api/subversion/include/svn_repos.h
    subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.c
    subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.h
    subversion/branches/fs-node-api/subversion/libsvn_fs/node_compat.c
    subversion/branches/fs-node-api/subversion/libsvn_fs_fs/node.c
    subversion/branches/fs-node-api/subversion/libsvn_ra_local/ra_plugin.c
    subversion/branches/fs-node-api/subversion/libsvn_repos/repos.c
    subversion/branches/fs-node-api/subversion/libsvn_repos/rev_hunt.c

Modified: subversion/branches/fs-node-api/subversion/include/svn_fs.h
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/include/svn_fs.h?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/include/svn_fs.h (original)
+++ subversion/branches/fs-node-api/subversion/include/svn_fs.h Sat Jan  9 19:20:41 2016
@@ -1819,14 +1819,23 @@ svn_fs_node_relation(svn_fs_node_relatio
                      apr_pool_t *scratch_pool);
 
 /** Set @a *revision to the revision in which the node-revision identified
- * by @a path under @a root was created; that is, to the revision in which
- * @a path under @a root was last modified.  @a *revision will
- * be set to #SVN_INVALID_REVNUM for uncommitted nodes (i.e. modified nodes
- * under a transaction root).  Note that the root of an unmodified transaction
- * is not itself considered to be modified; in that case, return the revision
- * upon which the transaction was based.
+ * by @a node was created; that is, to the revision in which @a node
+ * was last modified.  @a *revision will be set to #SVN_INVALID_REVNUM
+ * for uncommitted nodes (i.e. modified nodes under a transaction root).
+ * Note that the root of an unmodified transaction is not itself considered
+ * to be modified; in that case, return the revision upon which the
+ * transaction was based.
  *
- * Use @a pool for any temporary allocations.
+ * Use @a scratch_pool for any temporary allocations.
+ */
+svn_error_t *
+svn_fs_node_created_rev2(svn_revnum_t *revision,
+                         svn_fs_node_t *node,
+                         apr_pool_t *scratch_pool);
+
+/**
+ * Same as svn_fs_node_created_rev2(), but reference node by @a root and
+ * @a path.
  */
 svn_error_t *
 svn_fs_node_created_rev(svn_revnum_t *revision,
@@ -1874,10 +1883,23 @@ svn_fs_node_prop(svn_string_t **value_p,
                  apr_pool_t *pool);
 
 
-/** Set @a *table_p to the entire property list of @a path in @a root,
+/** Set @a *table_p to the entire property list of node @a node
  * as an APR hash table allocated in @a pool.  The resulting table maps
  * property names to pointers to #svn_string_t objects containing the
- * property value.
+ * property value.  Allocate the result in @a result_pool.  Perform
+ * temporary allocations in @a scratch_pool.
+ *
+ * @since New in 1.10.
+ */
+svn_error_t *
+svn_fs_node_proplist2(apr_hash_t **table_p,
+                      svn_fs_node_t *node,
+                      apr_pool_t *result_pool,
+                      apr_pool_t *scratch_pool);
+
+/**
+ * Same as svn_fs_node_proplist2(), but reference node by @a root and
+ * @a path.
  */
 svn_error_t *
 svn_fs_node_proplist(apr_hash_t **table_p,

Modified: subversion/branches/fs-node-api/subversion/include/svn_repos.h
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/include/svn_repos.h?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/include/svn_repos.h (original)
+++ subversion/branches/fs-node-api/subversion/include/svn_repos.h Sat Jan  9 19:20:41 2016
@@ -1672,8 +1672,8 @@ svn_repos_dated_revision(svn_revnum_t *r
                          apr_pool_t *pool);
 
 
-/** Given a @a root/@a path within some filesystem, return three pieces of
- * information allocated in @a pool:
+/** Given a @a node within some filesystem, return three pieces of
+ * information allocated in @a result_pool:
  *
  *    - set @a *committed_rev to the revision in which the object was
  *      last modified.  (In fs parlance, this is the revision in which
@@ -1684,6 +1684,23 @@ svn_repos_dated_revision(svn_revnum_t *r
  *
  *    - set @a *last_author to the author of said revision, or @c NULL
  *      if not available.
+ *
+ * Use @a scratch_pool for temporary allocations.
+ *
+ * @since New in 1.10.
+ */
+svn_error_t *
+svn_repos_get_committed_info2(svn_revnum_t *committed_rev,
+                              const char **committed_date,
+                              const char **last_author,
+                              svn_fs_node_t *node,
+                              apr_pool_t *result_pool,
+                              apr_pool_t *scratch_pool);
+
+
+/**
+ * Same as svn_repos_get_committed_info2(), but reference node by
+ * @a root and @a path.
  */
 svn_error_t *
 svn_repos_get_committed_info(svn_revnum_t *committed_rev,

Modified: subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.c Sat Jan  9 19:20:41 2016
@@ -1169,6 +1169,14 @@ svn_fs_node_created_rev(svn_revnum_t *re
 }
 
 svn_error_t *
+svn_fs_node_created_rev2(svn_revnum_t *revision, svn_fs_node_t *node,
+                         apr_pool_t *scratch_pool)
+{
+  return svn_error_trace(node->vtable->node_created_rev(revision, node,
+                                                        scratch_pool));
+}
+
+svn_error_t *
 svn_fs_node_origin_rev(svn_revnum_t *revision, svn_fs_root_t *root,
                        const char *path, apr_pool_t *pool)
 {
@@ -1201,6 +1209,15 @@ svn_fs_node_proplist(apr_hash_t **table_
 }
 
 svn_error_t *
+svn_fs_node_proplist2(apr_hash_t **table_p, svn_fs_node_t *node,
+                      apr_pool_t *result_pool, apr_pool_t *scratch_pool)
+{
+  return svn_error_trace(node->vtable->node_proplist(table_p, node,
+                                                     result_pool,
+                                                     scratch_pool));
+}
+
+svn_error_t *
 svn_fs_node_has_props(svn_boolean_t *has_props,
                       svn_fs_root_t *root,
                       const char *path,

Modified: subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.h
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.h?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.h (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_fs/fs-loader.h Sat Jan  9 19:20:41 2016
@@ -452,13 +452,21 @@ typedef struct id_vtable_t
 
 typedef struct node_vtable_t
 {
+  /* Generic node operations */
   svn_error_t *(*node_kind)(svn_node_kind_t *kind_p,
                             svn_fs_node_t *node,
                             apr_pool_t *scratch_pool);
+  svn_error_t *(*node_created_rev)(svn_revnum_t *revision_p,
+                                   svn_fs_node_t *node,
+                                   apr_pool_t *scratch_pool);
   /* Property operations */
   svn_error_t *(*node_has_props)(svn_boolean_t *has_props,
                                  svn_fs_node_t *node,
                                  apr_pool_t *scratch_pool);
+  svn_error_t *(*node_proplist)(apr_hash_t **proplist_p,
+                                svn_fs_node_t *node,
+                                apr_pool_t *result_pool,
+                                apr_pool_t *scratch_pool);
   /* Files */
   svn_error_t *(*file_length)(svn_filesize_t *length_p,
                               svn_fs_node_t *node,

Modified: subversion/branches/fs-node-api/subversion/libsvn_fs/node_compat.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_fs/node_compat.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_fs/node_compat.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_fs/node_compat.c Sat Jan  9 19:20:41 2016
@@ -66,6 +66,20 @@ compat_fs_node_kind(svn_node_kind_t *kin
 }
 
 static svn_error_t *
+compat_fs_node_created_rev(svn_revnum_t *revision_p,
+                           svn_fs_node_t *node,
+                           apr_pool_t *scratch_pool)
+{
+  compat_node_data_t *fnd = node->fsap_data;
+  svn_fs_root_t *root;
+  SVN_ERR(get_root(&root, fnd, scratch_pool));
+
+  return svn_error_trace(root->vtable->node_created_rev(revision_p, root,
+                                                        fnd->path,
+                                                        scratch_pool));
+}
+
+static svn_error_t *
 compat_fs_node_has_props(svn_boolean_t *has_props,
                          svn_fs_node_t *node,
                          apr_pool_t *scratch_pool)
@@ -80,6 +94,21 @@ compat_fs_node_has_props(svn_boolean_t *
 }
 
 static svn_error_t *
+compat_fs_node_proplist(apr_hash_t **proplist_p,
+                        svn_fs_node_t *node,
+                        apr_pool_t *result_pool,
+                        apr_pool_t *scratch_pool)
+{
+  compat_node_data_t *fnd = node->fsap_data;
+  svn_fs_root_t *root;
+  SVN_ERR(get_root(&root, fnd, scratch_pool));
+
+  return svn_error_trace(root->vtable->node_proplist(proplist_p, root,
+                                                     fnd->path,
+                                                     result_pool));
+}
+
+static svn_error_t *
 compat_fs_node_file_length(svn_filesize_t *length_p,
                            svn_fs_node_t *node,
                            apr_pool_t *pool)
@@ -135,7 +164,9 @@ compat_fs_node_dir_entries(apr_hash_t **
 static const node_vtable_t compat_node_vtable = 
 {
   compat_fs_node_kind,
+  compat_fs_node_created_rev,
   compat_fs_node_has_props,
+  compat_fs_node_proplist,
   compat_fs_node_file_length,
   compat_fs_node_dir_entries
 };

Modified: subversion/branches/fs-node-api/subversion/libsvn_fs_fs/node.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_fs_fs/node.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_fs_fs/node.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_fs_fs/node.c Sat Jan  9 19:20:41 2016
@@ -39,6 +39,19 @@ fs_node_kind(svn_node_kind_t *kind_p,
 }
 
 static svn_error_t *
+fs_node_created_rev(svn_revnum_t *revision_p,
+                    svn_fs_node_t *node,
+                    apr_pool_t *scratch_pool)
+{
+  fs_node_data_t *fnd = node->fsap_data;
+
+  SVN_ERR(svn_fs_fs__dag_get_revision(revision_p, fnd->dag_node,
+                                      scratch_pool));
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
 fs_node_has_props(svn_boolean_t *has_props,
                   svn_fs_node_t *node,
                   apr_pool_t *scratch_pool)
@@ -51,6 +64,20 @@ fs_node_has_props(svn_boolean_t *has_pro
 }
 
 static svn_error_t *
+fs_node_proplist(apr_hash_t **proplist_p,
+                 svn_fs_node_t *node,
+                 apr_pool_t *result_pool,
+                 apr_pool_t *scratch_pool)
+{
+  fs_node_data_t *fnd = node->fsap_data;
+
+  SVN_ERR(svn_fs_fs__dag_get_proplist(proplist_p, fnd->dag_node,
+                                      result_pool));
+
+  return SVN_NO_ERROR;
+}
+
+static svn_error_t *
 fs_node_file_length(svn_filesize_t *length_p,
                            svn_fs_node_t *node,
                            apr_pool_t *pool)
@@ -100,7 +127,9 @@ fs_node_dir_entries(apr_hash_t **entries
 static const node_vtable_t fs_node_vtable = 
 {
   fs_node_kind,
+  fs_node_created_rev,
   fs_node_has_props,
+  fs_node_proplist,
   fs_node_file_length,
   fs_node_dir_entries
 };

Modified: subversion/branches/fs-node-api/subversion/libsvn_ra_local/ra_plugin.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_ra_local/ra_plugin.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_ra_local/ra_plugin.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_ra_local/ra_plugin.c Sat Jan  9 19:20:41 2016
@@ -1192,8 +1192,7 @@ svn_ra_local__stat(svn_ra_session_t *ses
 /* Obtain the properties for a node, including its 'entry props */
 static svn_error_t *
 get_node_props(apr_hash_t **props,
-               svn_fs_root_t *root,
-               const char *path,
+               svn_fs_node_t *node,
                const char *uuid,
                apr_pool_t *result_pool,
                apr_pool_t *scratch_pool)
@@ -1202,14 +1201,14 @@ get_node_props(apr_hash_t **props,
   const char *cmt_date, *cmt_author;
 
   /* Create a hash with props attached to the fs node. */
-  SVN_ERR(svn_fs_node_proplist(props, root, path, result_pool));
+  SVN_ERR(svn_fs_node_proplist2(props, node, result_pool, scratch_pool));
 
   /* Now add some non-tweakable metadata to the hash as well... */
 
   /* The so-called 'entryprops' with info about CR & friends. */
-  SVN_ERR(svn_repos_get_committed_info(&cmt_rev, &cmt_date,
-                                       &cmt_author, root, path,
-                                       scratch_pool));
+  SVN_ERR(svn_repos_get_committed_info2(&cmt_rev, &cmt_date,
+                                        &cmt_author, node,
+                                        scratch_pool, scratch_pool));
 
   svn_hash_sets(*props, SVN_PROP_ENTRY_COMMITTED_REV,
                 svn_string_createf(result_pool, "%ld", cmt_rev));
@@ -1241,6 +1240,7 @@ svn_ra_local__get_file(svn_ra_session_t
   svn_revnum_t youngest_rev;
   svn_ra_local__session_baton_t *sess = session->priv;
   const char *abs_path = svn_fspath__join(sess->fs_path->data, path, pool);
+  svn_fs_node_t *node;
   svn_node_kind_t node_kind;
 
   /* Open the revision's root. */
@@ -1254,13 +1254,10 @@ svn_ra_local__get_file(svn_ra_session_t
   else
     SVN_ERR(svn_fs_revision_root(&root, sess->fs, revision, pool));
 
-  SVN_ERR(svn_fs_check_path(&node_kind, root, abs_path, pool));
-  if (node_kind == svn_node_none)
-    {
-      return svn_error_createf(SVN_ERR_FS_NOT_FOUND, NULL,
-                               _("'%s' path not found"), abs_path);
-    }
-  else if (node_kind != svn_node_file)
+  SVN_ERR(svn_fs_open_node(&node, root, abs_path, FALSE, pool, pool));
+  SVN_ERR(svn_fs_node_kind(&node_kind, node, pool));
+
+  if (node_kind != svn_node_file)
     {
       return svn_error_createf(SVN_ERR_FS_NOT_FILE, NULL,
                                _("'%s' is not a file"), abs_path);
@@ -1292,7 +1289,7 @@ svn_ra_local__get_file(svn_ra_session_t
 
   /* Handle props if requested. */
   if (props)
-    SVN_ERR(get_node_props(props, root, abs_path, sess->uuid, pool, pool));
+    SVN_ERR(get_node_props(props, node, sess->uuid, pool, pool));
 
   return SVN_NO_ERROR;
 }
@@ -1316,6 +1313,7 @@ svn_ra_local__get_dir(svn_ra_session_t *
   apr_hash_index_t *hi;
   svn_ra_local__session_baton_t *sess = session->priv;
   const char *abs_path = svn_fspath__join(sess->fs_path->data, path, pool);
+  svn_fs_node_t *node = NULL;
 
   /* Open the revision's root. */
   if (! SVN_IS_VALID_REVNUM(revision))
@@ -1328,12 +1326,13 @@ svn_ra_local__get_dir(svn_ra_session_t *
   else
     SVN_ERR(svn_fs_revision_root(&root, sess->fs, revision, pool));
 
+  if (dirents || props)
+    SVN_ERR(svn_fs_open_node(&node, root, abs_path, FALSE, pool, pool));
+
   if (dirents)
     {
-      svn_fs_node_t *node;
       apr_pool_t *iterpool = svn_pool_create(pool);
       /* Get the dir's entries. */
-      SVN_ERR(svn_fs_open_node(&node, root, abs_path, FALSE, pool, iterpool));
       SVN_ERR(svn_fs_dir_entries2(&entries, node, pool, iterpool));
 
       /* Loop over the fs dirents, and build a hash of general
@@ -1384,10 +1383,11 @@ svn_ra_local__get_dir(svn_ra_session_t *
               || (dirent_fields & SVN_DIRENT_CREATED_REV))
             {
               /* created_rev & friends */
-              SVN_ERR(svn_repos_get_committed_info(&(entry->created_rev),
-                                                   &datestring,
-                                                   &(entry->last_author),
-                                                   root, fullpath, iterpool));
+              SVN_ERR(svn_repos_get_committed_info2(&(entry->created_rev),
+                                                    &datestring,
+                                                    &(entry->last_author),
+                                                    fs_entry->node,
+                                                    iterpool, iterpool));
               if (datestring)
                 SVN_ERR(svn_time_from_cstring(&(entry->time), datestring,
                                               pool));
@@ -1403,7 +1403,7 @@ svn_ra_local__get_dir(svn_ra_session_t *
 
   /* Handle props if requested. */
   if (props)
-    SVN_ERR(get_node_props(props, root, abs_path, sess->uuid, pool, pool));
+    SVN_ERR(get_node_props(props, node, sess->uuid, pool, pool));
 
   return SVN_NO_ERROR;
 }

Modified: subversion/branches/fs-node-api/subversion/libsvn_repos/repos.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_repos/repos.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_repos/repos.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_repos/repos.c Sat Jan  9 19:20:41 2016
@@ -2083,10 +2083,10 @@ svn_repos_stat(svn_dirent_t **dirent,
 
   SVN_ERR(svn_fs_node_has_props2(&ent->has_props, node, pool));
 
-  SVN_ERR(svn_repos_get_committed_info(&(ent->created_rev),
-                                       &datestring,
-                                       &(ent->last_author),
-                                       root, path, pool));
+  SVN_ERR(svn_repos_get_committed_info2(&(ent->created_rev),
+                                        &datestring,
+                                        &(ent->last_author),
+                                        node, pool, pool));
   if (datestring)
     SVN_ERR(svn_time_from_cstring(&(ent->time), datestring, pool));
 

Modified: subversion/branches/fs-node-api/subversion/libsvn_repos/rev_hunt.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_repos/rev_hunt.c?rev=1723877&r1=1723876&r2=1723877&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_repos/rev_hunt.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_repos/rev_hunt.c Sat Jan  9 19:20:41 2016
@@ -151,16 +151,16 @@ svn_repos_dated_revision(svn_revnum_t *r
 
 
 svn_error_t *
-svn_repos_get_committed_info(svn_revnum_t *committed_rev,
-                             const char **committed_date,
-                             const char **last_author,
-                             svn_fs_root_t *root,
-                             const char *path,
-                             apr_pool_t *pool)
+svn_repos_get_committed_info2(svn_revnum_t *committed_rev,
+                              const char **committed_date,
+                              const char **last_author,
+                              svn_fs_node_t *node,
+                              apr_pool_t *result_pool,
+                              apr_pool_t *scratch_pool)
 {
   apr_hash_t *revprops;
 
-  svn_fs_t *fs = svn_fs_root_fs(root);
+  svn_fs_t *fs = svn_fs_node_fs(node);
 
   /* ### It might be simpler just to declare that revision
      properties have char * (i.e., UTF-8) values, not arbitrary
@@ -168,11 +168,11 @@ svn_repos_get_committed_info(svn_revnum_
   svn_string_t *committed_date_s, *last_author_s;
 
   /* Get the CR field out of the node's skel. */
-  SVN_ERR(svn_fs_node_created_rev(committed_rev, root, path, pool));
+  SVN_ERR(svn_fs_node_created_rev2(committed_rev, node, scratch_pool));
 
   /* Get the revision properties of this revision. */
   SVN_ERR(svn_fs_revision_proplist2(&revprops, fs, *committed_rev, TRUE,
-                                    pool, pool));
+                                    result_pool, scratch_pool));
 
   /* Extract date and author from these revprops. */
   committed_date_s = svn_hash_gets(revprops, SVN_PROP_REVISION_DATE);
@@ -183,6 +183,23 @@ svn_repos_get_committed_info(svn_revnum_
 
   return SVN_NO_ERROR;
 }
+
+svn_error_t *
+svn_repos_get_committed_info(svn_revnum_t *committed_rev,
+                             const char **committed_date,
+                             const char **last_author,
+                             svn_fs_root_t *root,
+                             const char *path,
+                             apr_pool_t *pool)
+{
+  svn_fs_node_t *node;
+
+  SVN_ERR(svn_fs_open_node(&node, root, path, FALSE, pool, pool));
+  SVN_ERR(svn_repos_get_committed_info2(committed_rev, committed_date,
+                                        last_author, node, pool, pool));
+
+  return SVN_NO_ERROR;
+}
 
 svn_error_t *
 svn_repos_history2(svn_fs_t *fs,