subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From i...@apache.org
Subject svn commit: r1723840 - in /subversion/branches/fs-node-api: ./ subversion/libsvn_fs_fs/tree.c
Date Sat, 09 Jan 2016 09:28:27 GMT
Author: ivan
Date: Sat Jan  9 09:28:27 2016
New Revision: 1723840

URL: http://svn.apache.org/viewvc?rev=1723840&view=rev
Log:
On 'fs-node-api' branch: Sync with trunk up to 1723839.

Modified:
    subversion/branches/fs-node-api/   (props changed)
    subversion/branches/fs-node-api/subversion/libsvn_fs_fs/tree.c

Propchange: subversion/branches/fs-node-api/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sat Jan  9 09:28:27 2016
@@ -95,3 +95,4 @@
 /subversion/branches/verify-at-commit:1462039-1462408
 /subversion/branches/verify-keep-going:1439280-1546110
 /subversion/branches/wc-collate-path:1402685-1480384
+/subversion/trunk:1723795-1723839

Modified: subversion/branches/fs-node-api/subversion/libsvn_fs_fs/tree.c
URL: http://svn.apache.org/viewvc/subversion/branches/fs-node-api/subversion/libsvn_fs_fs/tree.c?rev=1723840&r1=1723839&r2=1723840&view=diff
==============================================================================
--- subversion/branches/fs-node-api/subversion/libsvn_fs_fs/tree.c (original)
+++ subversion/branches/fs-node-api/subversion/libsvn_fs_fs/tree.c Sat Jan  9 09:28:27 2016
@@ -1474,29 +1474,6 @@ fs_node_created_path(const char **create
   return SVN_NO_ERROR;
 }
 
-
-/* Set *KIND_P to the type of node located at PATH under ROOT.
-   Perform temporary allocations in POOL. */
-static svn_error_t *
-node_kind(svn_node_kind_t *kind_p,
-          svn_fs_root_t *root,
-          const char *path,
-          apr_pool_t *pool)
-{
-  const svn_fs_id_t *node_id;
-  dag_node_t *node;
-
-  /* Get the node id. */
-  SVN_ERR(svn_fs_fs__node_id(&node_id, root, path, pool));
-
-  /* Use the node id to get the real kind. */
-  SVN_ERR(svn_fs_fs__dag_get_node(&node, root->fs, node_id, pool));
-  *kind_p = svn_fs_fs__dag_node_kind(node);
-
-  return SVN_NO_ERROR;
-}
-
-
 /* Set *KIND_P to the type of node present at PATH under ROOT.  If
    PATH does not exist under ROOT, set *KIND_P to svn_node_none.  Use
    POOL for temporary allocation. */
@@ -1506,17 +1483,23 @@ svn_fs_fs__check_path(svn_node_kind_t *k
                       const char *path,
                       apr_pool_t *pool)
 {
-  svn_error_t *err = node_kind(kind_p, root, path, pool);
+  dag_node_t *node;
+  svn_error_t *err;
+
+  err = get_dag(&node, root, path, pool);
   if (err &&
       ((err->apr_err == SVN_ERR_FS_NOT_FOUND)
        || (err->apr_err == SVN_ERR_FS_NOT_DIRECTORY)))
     {
       svn_error_clear(err);
-      err = SVN_NO_ERROR;
       *kind_p = svn_node_none;
+      return SVN_NO_ERROR;
     }
+  else if (err)
+    return svn_error_trace(err);
 
-  return svn_error_trace(err);
+  *kind_p = svn_fs_fs__dag_node_kind(node);
+  return SVN_NO_ERROR;
 }
 
 /* Set *VALUE_P to the value of the property named PROPNAME of PATH in



Mime
View raw message