subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hwri...@apache.org
Subject svn commit: r1208833 - in /subversion/trunk/subversion/libsvn_wc: status.c update_editor.c util.c wc.h
Date Wed, 30 Nov 2011 22:12:43 GMT
Author: hwright
Date: Wed Nov 30 22:12:42 2011
New Revision: 1208833

URL: http://svn.apache.org/viewvc?rev=1208833&view=rev
Log:
In libsvn_wc, when fetching props for the Ev2 shims, add a flag to the baton
so we can fetch the proper kind of props, either actual or base, depending on
the application.

Suggested by: rhuijben

* subversion/libsvn_wc/util.c
  (svn_wc__fetch_props_func): Fetch the appropriate kind of props.

* subversion/libsvn_wc/wc.h
  (svn_wc__shim_fetch_baton_t): Add flag.

* subversion/libsvn_wc/update_editor.c
  (make_editor): Fetch the base props.

* subversion/libsvn_wc/status.c
  (svn_wc_get_status_editor5): Fetch the actual props.

Modified:
    subversion/trunk/subversion/libsvn_wc/status.c
    subversion/trunk/subversion/libsvn_wc/update_editor.c
    subversion/trunk/subversion/libsvn_wc/util.c
    subversion/trunk/subversion/libsvn_wc/wc.h

Modified: subversion/trunk/subversion/libsvn_wc/status.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/status.c?rev=1208833&r1=1208832&r2=1208833&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/status.c (original)
+++ subversion/trunk/subversion/libsvn_wc/status.c Wed Nov 30 22:12:42 2011
@@ -2549,6 +2549,7 @@ svn_wc_get_status_editor5(const svn_delt
   sfb = apr_palloc(result_pool, sizeof(*sfb));
   sfb->db = wc_ctx->db;
   sfb->base_abspath = eb->target_abspath;
+  sfb->fetch_base = FALSE;
 
   shim_callbacks->fetch_kind_func = svn_wc__fetch_kind_func;
   shim_callbacks->fetch_kind_baton = sfb;

Modified: subversion/trunk/subversion/libsvn_wc/update_editor.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/update_editor.c?rev=1208833&r1=1208832&r2=1208833&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/update_editor.c (original)
+++ subversion/trunk/subversion/libsvn_wc/update_editor.c Wed Nov 30 22:12:42 2011
@@ -4989,6 +4989,7 @@ make_editor(svn_revnum_t *target_revisio
   sfb = apr_palloc(result_pool, sizeof(*sfb));
   sfb->db = db;
   sfb->base_abspath = eb->target_abspath;
+  sfb->fetch_base = TRUE;
 
   shim_callbacks->fetch_kind_func = svn_wc__fetch_kind_func;
   shim_callbacks->fetch_kind_baton = sfb;

Modified: subversion/trunk/subversion/libsvn_wc/util.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/util.c?rev=1208833&r1=1208832&r2=1208833&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/util.c (original)
+++ subversion/trunk/subversion/libsvn_wc/util.c Wed Nov 30 22:12:42 2011
@@ -564,8 +564,12 @@ svn_wc__fetch_props_func(apr_hash_t **pr
                                               scratch_pool);
   svn_error_t *err;
 
-  err = svn_wc__db_read_props(props, sfb->db, local_abspath,
-                              result_pool, scratch_pool);
+  if (sfb->fetch_base)
+    err = svn_wc__db_base_get_props(props, sfb->db, local_abspath, result_pool,
+                                    scratch_pool);
+  else
+    err = svn_wc__db_read_props(props, sfb->db, local_abspath,
+                                result_pool, scratch_pool);
 
   /* If the path doesn't exist, just return an empty set of props. */
   if (err && err->apr_err == SVN_ERR_WC_PATH_NOT_FOUND)

Modified: subversion/trunk/subversion/libsvn_wc/wc.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/wc.h?rev=1208833&r1=1208832&r2=1208833&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/wc.h (original)
+++ subversion/trunk/subversion/libsvn_wc/wc.h Wed Nov 30 22:12:42 2011
@@ -730,6 +730,7 @@ struct svn_wc__shim_fetch_baton_t
 {
   svn_wc__db_t *db;
   const char *base_abspath;
+  svn_boolean_t fetch_base;
 };
 
 /* Using a BATON of struct shim_fetch_baton, return KIND for PATH. */



Mime
View raw message