You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by hw...@apache.org on 2011/04/22 19:46:30 UTC
svn commit: r1095971 - in /subversion/trunk/subversion: include/svn_wc.h
libsvn_client/add.c libsvn_client/mergeinfo.c libsvn_client/patch.c
libsvn_client/prop_commands.c libsvn_client/ra.c libsvn_wc/deprecated.c
libsvn_wc/props.c libsvn_wc/props.h
Author: hwright
Date: Fri Apr 22 17:46:29 2011
New Revision: 1095971
URL: http://svn.apache.org/viewvc?rev=1095971&view=rev
Log:
Add depth parameter to the libsvn_wc propset function. We currently only
support depth = empty, so assert that fact. (This should change shortly.)
* subversion/include/svn_wc.h
(svn_wc_prop_set4): Add param and update docs.
* subversion/libsvn_wc/deprecated.c
(svn_wc_prop_set3): Update caller.
* subversion/libsvn_wc/props.c
(svn_wc__internal_propset): Add depth param, and assert that it is
set to svn_depth_empty.
(svn_wc_prop_set4): Add depth param.
* subversion/libsvn_wc/props.h
(svn_wc__internal_propset): Add depth param.
* subversion/libsvn_client/patch.c
(install_patched_prop_targets): Update caller.
* subversion/libsvn_client/prop_commands.c
(propset_walk_cb, set_props_cb): Same.
* subversion/libsvn_client/ra.c
(set_wc_prop): Same.
* subversion/libsvn_client/mergeinfo.c
(svn_client__record_wc_mergeinfo, elide_mergeinfo): Same.
* subversion/libsvn_client/add.c
(add_file): Same.
Modified:
subversion/trunk/subversion/include/svn_wc.h
subversion/trunk/subversion/libsvn_client/add.c
subversion/trunk/subversion/libsvn_client/mergeinfo.c
subversion/trunk/subversion/libsvn_client/patch.c
subversion/trunk/subversion/libsvn_client/prop_commands.c
subversion/trunk/subversion/libsvn_client/ra.c
subversion/trunk/subversion/libsvn_wc/deprecated.c
subversion/trunk/subversion/libsvn_wc/props.c
subversion/trunk/subversion/libsvn_wc/props.h
Modified: subversion/trunk/subversion/include/svn_wc.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_wc.h?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_wc.h (original)
+++ subversion/trunk/subversion/include/svn_wc.h Fri Apr 22 17:46:29 2011
@@ -5737,6 +5737,9 @@ svn_wc_prop_get(const svn_string_t **val
* #SVN_ERR_BAD_MIME_TYPE (if @a name is "svn:mime-type", but @a value
* is not a valid mime-type).
*
+ * @a depth follows the usual semeatic for depth.
+ * @note Currently only #svn_depth_empty is supported.
+ *
* @a name may be a wc property or a regular property; but if it is an
* entry property, return the error #SVN_ERR_BAD_PROP_KIND, even if
* @a skip_checks is TRUE.
@@ -5754,6 +5757,7 @@ svn_wc_prop_set4(svn_wc_context_t *wc_ct
const char *local_abspath,
const char *name,
const svn_string_t *value,
+ svn_depth_t depth,
svn_boolean_t skip_checks,
svn_wc_notify_func2_t notify_func,
void *notify_baton,
Modified: subversion/trunk/subversion/libsvn_client/add.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/add.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/add.c (original)
+++ subversion/trunk/subversion/libsvn_client/add.c Fri Apr 22 17:46:29 2011
@@ -307,7 +307,7 @@ add_file(const char *local_abspath,
/* This must be a special file. */
SVN_ERR(svn_wc_prop_set4(ctx->wc_ctx, local_abspath, SVN_PROP_SPECIAL,
svn_string_create(SVN_PROP_BOOLEAN_TRUE, pool),
- FALSE, NULL, NULL, pool));
+ svn_depth_empty, FALSE, NULL, NULL, pool));
else if (properties)
{
/* loop through the hashtable and add the properties */
@@ -322,7 +322,7 @@ add_file(const char *local_abspath,
the autoprops say to set some weird combination,
we just error and let the user sort it out. */
err = svn_wc_prop_set4(ctx->wc_ctx, local_abspath, pname, pval,
- FALSE, NULL, NULL, pool);
+ svn_depth_empty, FALSE, NULL, NULL, pool);
if (err)
{
/* Don't leave the job half-done. If we fail to set a property,
Modified: subversion/trunk/subversion/libsvn_client/mergeinfo.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/mergeinfo.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/mergeinfo.c (original)
+++ subversion/trunk/subversion/libsvn_client/mergeinfo.c Fri Apr 22 17:46:29 2011
@@ -113,7 +113,8 @@ svn_client__record_wc_mergeinfo(const ch
/* ### Later, we'll want behavior more analogous to
### svn_client__get_prop_from_wc(). */
SVN_ERR(svn_wc_prop_set4(ctx->wc_ctx, local_abspath, SVN_PROP_MERGEINFO,
- mergeinfo_str, TRUE /* skip checks */, NULL, NULL,
+ mergeinfo_str, svn_depth_empty,
+ TRUE /* skip checks */, NULL, NULL,
scratch_pool));
if (do_notification && ctx->notify_func2)
@@ -787,7 +788,8 @@ elide_mergeinfo(svn_mergeinfo_t parent_m
if (elides)
{
SVN_ERR(svn_wc_prop_set4(ctx->wc_ctx, local_abspath, SVN_PROP_MERGEINFO,
- NULL, TRUE, NULL, NULL, scratch_pool));
+ NULL, svn_depth_empty, TRUE, NULL, NULL,
+ scratch_pool));
if (ctx->notify_func2)
{
Modified: subversion/trunk/subversion/libsvn_client/patch.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/patch.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/patch.c (original)
+++ subversion/trunk/subversion/libsvn_client/patch.c Fri Apr 22 17:46:29 2011
@@ -2221,7 +2221,7 @@ install_patched_prop_targets(patch_targe
{
if (! dry_run)
SVN_ERR(svn_wc_prop_set4(ctx->wc_ctx, target->local_abspath,
- prop_target->name, NULL,
+ prop_target->name, NULL, svn_depth_empty,
TRUE /* skip_checks */,
NULL, NULL, /* suppress notification */
iterpool));
@@ -2297,7 +2297,7 @@ install_patched_prop_targets(patch_targe
else
{
err = (svn_wc_prop_set4(ctx->wc_ctx, target->local_abspath,
- prop_target->name, prop_val,
+ prop_target->name, prop_val, svn_depth_empty,
TRUE, /* ### Skipping checks */
NULL, NULL,
iterpool));
Modified: subversion/trunk/subversion/libsvn_client/prop_commands.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/prop_commands.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/prop_commands.c (original)
+++ subversion/trunk/subversion/libsvn_client/prop_commands.c Fri Apr 22 17:46:29 2011
@@ -119,7 +119,8 @@ propset_walk_cb(const char *local_abspat
return SVN_NO_ERROR;
err = svn_wc_prop_set4(wb->wc_ctx, local_abspath, wb->propname, wb->propval,
- wb->force, wb->notify_func, wb->notify_baton, pool);
+ svn_depth_empty, wb->force, wb->notify_func,
+ wb->notify_baton, pool);
if (err && (err->apr_err == SVN_ERR_ILLEGAL_TARGET
|| err->apr_err == SVN_ERR_WC_INVALID_SCHEDULE))
{
@@ -334,7 +335,8 @@ set_props_cb(void *baton,
bt->changelist_hash, scratch_pool))
{
SVN_ERR(svn_wc_prop_set4(bt->ctx->wc_ctx, bt->local_abspath,
- bt->propname, bt->propval, bt->skip_checks,
+ bt->propname, bt->propval, svn_depth_empty,
+ bt->skip_checks,
bt->ctx->notify_func2, bt->ctx->notify_baton2,
scratch_pool));
}
Modified: subversion/trunk/subversion/libsvn_client/ra.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/ra.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/ra.c (original)
+++ subversion/trunk/subversion/libsvn_client/ra.c Fri Apr 22 17:46:29 2011
@@ -197,7 +197,8 @@ set_wc_prop(void *baton,
Unfortunately, we don't have a clean mechanism for doing that
here, so we just set the property and hope for the best. */
return svn_error_return(svn_wc_prop_set4(cb->ctx->wc_ctx, local_abspath, name,
- value, TRUE, NULL, NULL, pool));
+ value, svn_depth_empty, TRUE, NULL,
+ NULL, pool));
}
Modified: subversion/trunk/subversion/libsvn_wc/deprecated.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/deprecated.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/deprecated.c (original)
+++ subversion/trunk/subversion/libsvn_wc/deprecated.c Fri Apr 22 17:46:29 2011
@@ -2190,8 +2190,8 @@ svn_wc_prop_set3(const char *name,
SVN_ERR(svn_wc__context_create_with_db(&wc_ctx, NULL /* config */,
svn_wc__adm_get_db(adm_access), pool));
- err = svn_wc_prop_set4(wc_ctx, local_abspath, name, value, skip_checks,
- notify_func, notify_baton, pool);
+ err = svn_wc_prop_set4(wc_ctx, local_abspath, name, value, svn_depth_empty,
+ skip_checks, notify_func, notify_baton, pool);
if (err && err->apr_err == SVN_ERR_WC_INVALID_SCHEDULE)
svn_error_clear(err);
Modified: subversion/trunk/subversion/libsvn_wc/props.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/props.c?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/props.c (original)
+++ subversion/trunk/subversion/libsvn_wc/props.c Fri Apr 22 17:46:29 2011
@@ -2007,6 +2007,7 @@ svn_wc__internal_propset(svn_wc__db_t *d
const char *local_abspath,
const char *name,
const svn_string_t *value,
+ svn_depth_t depth,
svn_boolean_t skip_checks,
svn_wc_notify_func2_t notify_func,
void *notify_baton,
@@ -2020,6 +2021,8 @@ svn_wc__internal_propset(svn_wc__db_t *d
const char *dir_abspath;
SVN_ERR_ASSERT(svn_dirent_is_absolute(local_abspath));
+ /* ### For the time being, only support depth = empty */
+ SVN_ERR_ASSERT(depth == svn_depth_empty);
/* Get the node kind for this path. */
SVN_ERR(svn_wc__db_read_info(&status, &kind, NULL, NULL, NULL, NULL, NULL,
@@ -2208,14 +2211,15 @@ svn_wc_prop_set4(svn_wc_context_t *wc_ct
const char *local_abspath,
const char *name,
const svn_string_t *value,
+ svn_depth_t depth,
svn_boolean_t skip_checks,
svn_wc_notify_func2_t notify_func,
void *notify_baton,
apr_pool_t *scratch_pool)
{
return svn_error_return(svn_wc__internal_propset(wc_ctx->db, local_abspath,
- name, value, skip_checks, notify_func,
- notify_baton, scratch_pool));
+ name, value, depth, skip_checks,
+ notify_func, notify_baton, scratch_pool));
}
Modified: subversion/trunk/subversion/libsvn_wc/props.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_wc/props.h?rev=1095971&r1=1095970&r2=1095971&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_wc/props.h (original)
+++ subversion/trunk/subversion/libsvn_wc/props.h Fri Apr 22 17:46:29 2011
@@ -75,6 +75,7 @@ svn_wc__internal_propset(svn_wc__db_t *d
const char *local_abspath,
const char *name,
const svn_string_t *value,
+ svn_depth_t depth,
svn_boolean_t skip_checks,
svn_wc_notify_func2_t notify_func,
void *notify_baton,