You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by iv...@apache.org on 2013/06/15 23:54:05 UTC
svn commit: r1493424 - in /subversion/trunk/subversion/svn: cl.h merge-cmd.c
mergeinfo-cmd.c util.c
Author: ivan
Date: Sat Jun 15 21:54:05 2013
New Revision: 1493424
URL: http://svn.apache.org/r1493424
Log:
Follow-up to 1489203: Remove unnecessary check for branches ancestry from
command line client. All required checks are performed in libsvn_client.
* subversion/svn/cl.h
* subversion/svn/util.c
(svn_cl__check_related_source_and_target): Remove
* subversion/svn/merge-cmd.c
* subversion/svn/mergeinfo-cmd.c
(run_merge, svn_cl__mergeinfo): Remove call to
svn_cl__check_related_source_and_target().
Modified:
subversion/trunk/subversion/svn/cl.h
subversion/trunk/subversion/svn/merge-cmd.c
subversion/trunk/subversion/svn/mergeinfo-cmd.c
subversion/trunk/subversion/svn/util.c
Modified: subversion/trunk/subversion/svn/cl.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/cl.h?rev=1493424&r1=1493423&r2=1493424&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/cl.h (original)
+++ subversion/trunk/subversion/svn/cl.h Sat Jun 15 21:54:05 2013
@@ -821,23 +821,6 @@ svn_cl__local_style_skip_ancestor(const
const char *path,
apr_pool_t *pool);
-/* Check that PATH_OR_URL1@REVISION1 is related to PATH_OR_URL2@REVISION2.
- * Raise an error if not.
- *
- * ### Ideally we would also check that they are on different lines of
- * history. That is easy in common cases, but to give a correct answer in
- * general we need to know the operative revision(s) as well. For example,
- * when one location is the branch point from which the other branch was
- * copied.
- */
-svn_error_t *
-svn_cl__check_related_source_and_target(const char *path_or_url1,
- const svn_opt_revision_t *revision1,
- const char *path_or_url2,
- const svn_opt_revision_t *revision2,
- svn_client_ctx_t *ctx,
- apr_pool_t *pool);
-
/* If the user is setting a mime-type to mark one of the TARGETS as binary,
* as determined by property name PROPNAME and value PROPVAL, then check
* whether Subversion's own binary-file detection recognizes the target as
Modified: subversion/trunk/subversion/svn/merge-cmd.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/merge-cmd.c?rev=1493424&r1=1493423&r2=1493424&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/merge-cmd.c (original)
+++ subversion/trunk/subversion/svn/merge-cmd.c Sat Jun 15 21:54:05 2013
@@ -101,15 +101,6 @@ run_merge(svn_boolean_t two_sources_spec
&& (first_range_end.kind == svn_opt_revision_unspecified))
{
ranges_to_merge = NULL;
-
- /* This must be a 'sync' merge so check branch relationship. */
- if (opt_state->verbose)
- SVN_ERR(svn_cmdline_printf(
- scratch_pool, _("--- Checking branch relationship\n")));
- SVN_ERR_W(svn_cl__check_related_source_and_target(
- sourcepath1, &peg_revision1,
- targetpath, &unspecified_revision, ctx, scratch_pool),
- _("Source and target must be different but related branches"));
}
if (opt_state->verbose)
Modified: subversion/trunk/subversion/svn/mergeinfo-cmd.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/mergeinfo-cmd.c?rev=1493424&r1=1493423&r2=1493424&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/mergeinfo-cmd.c (original)
+++ subversion/trunk/subversion/svn/mergeinfo-cmd.c Sat Jun 15 21:54:05 2013
@@ -398,11 +398,6 @@ svn_cl__mergeinfo(apr_getopt_t *os,
tgt_peg_revision.kind = svn_opt_revision_base;
}
- SVN_ERR_W(svn_cl__check_related_source_and_target(source, &src_peg_revision,
- target, &tgt_peg_revision,
- ctx, pool),
- _("Source and target must be different but related branches"));
-
src_start_revision = &(opt_state->start_revision);
if (opt_state->end_revision.kind == svn_opt_revision_unspecified)
src_end_revision = src_start_revision;
Modified: subversion/trunk/subversion/svn/util.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/util.c?rev=1493424&r1=1493423&r2=1493424&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/util.c (original)
+++ subversion/trunk/subversion/svn/util.c Sat Jun 15 21:54:05 2013
@@ -1021,33 +1021,6 @@ path_for_display(const char *path_or_url
}
svn_error_t *
-svn_cl__check_related_source_and_target(const char *path_or_url1,
- const svn_opt_revision_t *revision1,
- const char *path_or_url2,
- const svn_opt_revision_t *revision2,
- svn_client_ctx_t *ctx,
- apr_pool_t *pool)
-{
- const char *ancestor_url;
- svn_revnum_t ancestor_rev;
-
- SVN_ERR(svn_client__youngest_common_ancestor(
- &ancestor_url, &ancestor_rev,
- path_or_url1, revision1, path_or_url2, revision2,
- ctx, pool, pool));
-
- if (ancestor_url == NULL)
- {
- return svn_error_createf(SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
- _("Source and target have no common ancestor: "
- "'%s' and '%s'"),
- path_for_display(path_or_url1, revision1, pool),
- path_for_display(path_or_url2, revision2, pool));
- }
- return SVN_NO_ERROR;
-}
-
-svn_error_t *
svn_cl__propset_print_binary_mime_type_warning(apr_array_header_t *targets,
const char *propname,
const svn_string_t *propval,