Checkout Tools
  • last updated 6 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Update calls to three deprecated APIs to use svn_client_get_repos_root()

instead, mark the deprecated APIs as such and move their implementations to

'deprecated.c'. A follow-up to r1186244.

* subversion/include/svn_client.h

(svn_client_get_repos_root): Mention that it may open a temporary RA

session.

(svn_client_root_url_from_path, svn_client_uuid_from_url,

svn_client_uuid_from_path2): Mark as deprecated.

* subversion/libsvn_client/ra.c

(svn_client_uuid_from_url, svn_client_uuid_from_path2): Move these ...

* subversion/libsvn_client/url.c

(svn_client_root_url_from_path): ... and this ...

* subversion/libsvn_client/deprecated.c

(svn_client_uuid_from_url, svn_client_uuid_from_path2,

svn_client_root_url_from_path): ... to here.

* subversion/libsvn_client/cmdline.c

(svn_client_args_to_target_array2): Update calls.

* subversion/libsvn_client/copy.c

(repos_to_wc_copy_locked): Update calls.

* subversion/libsvn_client/merge.c

(merge_cousins_and_supplement_mergeinfo): Update calls.

* subversion/libsvn_client/relocate.c

(relocate_externals, svn_client_relocate2): Update calls.

  1. … 7 more files in changeset.
Promote svn_client__get_repos_root() to a public API, deprecating three APIs

that performed subsets of that operation. Calls to the deprecated APIs are

not updated in this commit.

* subversion/libsvn_client/client.h

(svn_client__get_repos_root): Rename and move to ...

* subversion/include/svn_client.h

(svn_client_get_repos_root): ... here.

(svn_client_root_url_from_path, svn_client_uuid_from_url,

svn_client_uuid_from_path2): Deprecate.

* subversion/libsvn_client/cmdline.c

(check_root_url_of_target): Track the rename.

* subversion/libsvn_client/merge.c

(merge_locked, merge_reintegrate_locked, merge_peg_locked): Same.

* subversion/libsvn_client/url.c

(svn_client_root_url_from_path): Same.

* subversion/libsvn_client/util.c

(svn_client__get_repos_root): Rename.

  1. … 5 more files in changeset.
Tweak an internal API for simplicity. Let svn_client__get_repos_root()

optionally return the repository UUID at the same time as the root URL,

since those two bits of information go together. Simplify some callers by

taking advange of that.

* subversion/libsvn_client/client.h

* subversion/libsvn_client/util.c

(svn_client__get_repos_root): Add a UUID output parameter and make both

outputs optional.

* subversion/libsvn_client/merge.c

(merge_locked, merge_peg_locked): Simplify by getting the UUID and URL

together.

(merge_reintegrate_locked): Pass NULL for the UUID output parameter.

* subversion/libsvn_client/cmdline.c

(check_root_url_of_target): Pass NULL for the UUID output parameter.

* subversion/libsvn_client/url.c

(svn_client_root_url_from_path): Pass NULL for the UUID output parameter.

  1. … 4 more files in changeset.
Rename the 'svn_error_return' macro to 'svn_error_trace'.

See email thread "[RFC] Rename 'svn_error_return' to 'svn_error_trace'?" on

2011-06-23, <http://svn.haxx.se/dev/archive-2011-06/0708.shtml>.

* subversion/include/svn_error.h

(svn_error_return): Rename to svn_error_trace.

(SVN_ERR, svn_error_purge_tracing): Track the rename.

* [everywhere]: Track the rename.

  1. … 120 more files in changeset.
* subversion/libsvn_client/url.c

(svn_client_url_from_path2): Instead of just copying the url, canonicalize

it using the uri rules. This handles some possible cases where the user

used the old svn_path_canonicalize() before calling functions that

translate path via this api. Most importantly svn_client_list2().

Make the mergeinfo code use the standard code for resolving local paths to

urls and revisions to numbers. It reimplemented this logic (sometimes using

a temp ra session) and then contacted the repository anyway.

This simplifies all this logic and allows removing some barely tested

utility functions. (And it avoids creating a few ra sessions in common

scenarios).

* subversion/libsvn_client/client.h

(svn_client__derive_location): Remove function.

(svn_client__entry_location): Remove function.

* subversion/libsvn_client/mergeinfo.c

(svn_client__get_history_as_mergeinfo): When we don't have a session, resolve

using our standard function for that.

Otherwise just resolve the revision.

(get_mergeinfo): Resolve url by opening the ra session that we need

anyway. Allocate repository root in the result_pool. Remove some

duplication.

(location_from_path_and_rev): Remove function.

(svn_client_mergeinfo_log): Don't use location_from_path_and_rev to resolve

a path and rev for a function that accepts them unresolved and can

resolve them easier itself.

* subversion/libsvn_client/url.c

(svn_client__derive_location): Remove function.

(svn_client__entry_location): Remove function.

* subversion/svnrdump/svnrdump.c

(main): Accidental change. Reverted in r1102750.

  1. … 3 more files in changeset.
Following up on r1092145, use svn_wc__node_get_origin() in the major

libsvn_client url helper functions.

* subversion/libsvn_client/ra.c

(svn_client__repos_locations): Use the origin function to avoid further db

calls in the very common working case.

* subversion/libsvn_client/url.c

(svn_client__entry_location): Rewrite to take advantage of

svn_wc__node_get_origin() for all common code paths.

  1. … 1 more file in changeset.
Fix failing regression tests.

* subversion/libsvn_client/url.c

(svn_client_root_url_from_path): Convert path to abspath.

A bit more cleanup of libsvn_client's url helper functions.

* subversion/libsvn_client/client.h

(svn_client__get_repos_root): Remove unused argument.

* subversion/libsvn_client/cmdline.c

(check_root_url_of_target): Update caller.

* subversion/libsvn_client/externals.c

(switch_file_external): Update caller.

* subversion/libsvn_client/merge.c

(merge_locked, merge_reintegrate_locked,

merge_peg_locked): Update callers.

* subversion/libsvn_client/mergeinfo.c

(get_mergeinfo): Update caller.

* subversion/libsvn_client/url.c

(svn_client_url_from_path2): Do the minimal amount of work instead of

using svn_client__derive_location.

(svn_client_root_url_from_path): Update caller.

* subversion/libsvn_client/util.c

(svn_client__path_relative_to_root): Fix TODO by making it explicit that

there are three cases.

(svn_client__get_repos_root): Remove unused argument and two unused variables.

  1. … 6 more files in changeset.
Reintegrate the issue-2779-dev branch. Permanent redirect responses

from an HTTP server now cause the client -- in particular

circumstances -- to automatically follow the redirect.

NOTE: The test suite changes brought in by this merge require

modifications to developers' httpd.conf files. So if you see the

redirect_tests.py all failing, make sure you've updated your Apache

configuration per the instructions in the

subversion/tests/cmdline/README file.

  1. … 44 more files in changeset.
Teach svn_wc__node_get_copyfrom_info() to also return the URL as separate root

and relpath. There should be no "real" changes with this patch except some

slight micro-optimisations (this isn't used yet, breaking up a larger patch).

* subversion/include/private/svn_wc_private.h,

* subversion/libsvn_wc/node.c

(svn_wc__node_get_copyfrom_info):

Add parameters COPYFROM_ROOT_URL and COPYFROM_REPOS_RELPATH.

* subversion/libsvn_client/commit_util.c (harvest_committables),

* subversion/libsvn_client/copy.c (calculate_target_mergeinfo, try_copy),

* subversion/libsvn_client/export.c (copy_versioned_files),

* subversion/libsvn_client/info.c (build_info_for_entry),

* subversion/libsvn_client/ra.c (svn_client__repos_locations),

* subversion/libsvn_client/url.c (svn_client__entry_location):

Pass NULL for the two new parameters of svn_wc__node_get_copyfrom_info(),

except, when only the presence of copyfrom information is tested, don't

bother to get a full URL and ask for the COPYFROM_REPOS_ROOT only.

  1. … 7 more files in changeset.
Teach svn_wc__node_get_copyfrom_info() to handle optional return

values and (optionally) return the information required to tell the

difference between "direct target of a copy" and "item in a copied

subtree".

* subversion/include/private/svn_wc_private.h

(svn_wc__node_get_copyfrom_info): Add 'is_copy_target' parameter,

and update docstring.

* subversion/libsvn_wc/node.c

(svn_wc__node_get_copyfrom_info): Add 'is_copy_target' parameter and

handling, plus allow any of the return variables to be NULL.

* subversion/libsvn_client/ra.c

(svn_client__repos_locations): Update call to

svn_wc__node_get_copyfrom_info().

* subversion/libsvn_client/url.c

(svn_client__entry_location): Update call to

svn_wc__node_get_copyfrom_info().

* subversion/libsvn_wc/copy.c

(copy_file_administratively, copy_dir_administratively): Update call to

svn_wc__node_get_copyfrom_info().

* subversion/libsvn_client/copy.c

(try_copy): Update call to svn_wc__node_get_copyfrom_info().

  1. … 5 more files in changeset.
More svn_wc_entry_t purging from libsvn_client.

* subversion/libsvn_client/url.c

(svn_client__entry_location): Use WC-NG node functions instead of

svn_wc_entry_t queries.

Fix 'svn mergeinfo' bug when target is a WC path pegged at HEAD or DATE.

This fixes the failing JavaHL test BasicTests.java:testBasicMerge.

See http://svn.haxx.se/dev/archive-2009-12/0346.shtml.

* subversion/libsvn_client/url.c

(svn_client__derive_location): Follow-up to r886880; contact the server if

asking about a working copy path pegged at DATE or HEAD. Previously we

tried to resolve the peg rev in this case with a call to

svn_client__entry_location(), but since r886880 that function has

returned an error if asked about revisions only the repos knows about.

* subversion/tests/cmdline/mergeinfo_tests.py

(mergeinfo_on_pegged_wc_path): Fix typo, this test should have tested

WC paths pegged at HEAD, but was instead twice testing WC paths pegged

at BASE. Also add --show-revs=eligible variants of the tests.

  1. … 1 more file in changeset.
Fix a peg rev bug in a libsvn_client private function.

* subversion/libsvn_client/url.c

(svn_client__entry_location): Return an error if asked about a peg rev

which requires communication with the repository. Actually return the

COMMITED or PREV revision if asked for those. Previously we returned

the base rev (i.e. entry->rev) in all cases.

* subversion/libsvn_client/client.h

(svn_client__entry_location): Get specific about what this function does

and does not do.

  1. … 1 more file in changeset.
Test out my new and fancy ASF commit priviledges by changing the copyright

wording in our license headers to reflect ownership by the ASF.

* NOTICE:

Change terminology to ASF, and update a link.

* subversion/libsvn_subr/opt.c

(svn_opt__print_version_info): Note that the product as a whole is

copyrighted by the ASF, and update the project website.

* everywhere:

Change license text to reflect ASF ownership.

  1. … 891 more files in changeset.
Fetch an entry locally inside a function, rather than requiring it to be

fetched by the caller and provided.

* subversion/libsvn_client/util.c

(wc_path_to_repos_urls): Update caller.

* subversion/libsvn_client/client.h

(svn_client__entry_location): Take an absolute path and context, as well

as result and scratch pools. Update docs.

* subversion/libsvn_client/url.c

(svn_client__derive_location): Don't fetch an entry, just call the API.

(svn_client__entry_location): Fetch the required entry internally,

duplicate the results into the output pool.

* subversion/libsvn_client/copy.c

(calculate_target_mergeinfo): Update caller.

* subversion/libsvn_client/mergeinfo.c

(svn_client__get_wc_or_repos_mergeinfo_catalog, get_mergeinfo): Same.

  1. … 4 more files in changeset.

* subversion/libsvn_client/client.h

(svn_client__open_ra_session_internal): Remove access baton parameter,

and update docs.

* subversion/libsvn_client/ra.c

(svn_client__open_ra_session_internal): Remove the now-unused access baton

parameter.

* subversion/libsvn_client/relocate.c,

subversion/libsvn_client/delete.c,

subversion/libsvn_client/externals.c,

subversion/libsvn_client/status.c,

subversion/libsvn_client/info.c,

subversion/libsvn_client/merge.c,

subversion/libsvn_client/prop_commands.c,

subversion/libsvn_client/url.c,

subversion/libsvn_client/ra.c,

subversion/libsvn_client/locking_commands.c,

subversion/libsvn_client/diff.c,

subversion/libsvn_client/copy.c,

subversion/libsvn_client/list.c,

subversion/libsvn_client/mergeinfo.c,

subversion/libsvn_client/update.c,

subversion/libsvn_client/add.c,

subversion/libsvn_client/commit.c:

Update callers throughout by removing the access baton parameter.

  1. … 17 more files in changeset.
* subversion/include/svn_client.h

(svn_client_url_from_path2): New function.

(svn_client_url_from_path): Deprecate function.

* subversion/libsvn_client/deprecated.c

(svn_client_url_from_path2): Reimplement as wrapper.

* subversion/libsvn_client/merge.c

(filter_self_referential_mergeinfo, svn_client_merge3,

svn_client_merge_reintegrate, svn_client_merge_peg3):

Use new svn_client_url_from_path2().

* subversion/libsvn_client/ra.c

(svn_client__ra_session_from_path):

Use new svn_client_url_from_path2().

* subversion/libsvn_client/url.c

(svn_client_url_from_path): Renamed to ..

(svn_client_url_from_path2): .. this and don't create a new context.

  1. … 4 more files in changeset.
Update another client API to use svn_wc__get_entry_versioned(). Propagate

access baton removal to several calling functions.

* subversion/libsvn_client/client.h

(svn_client_derive_location): Remove access baton, stipulate an absolute

path, and take a result_pool and scratch_pool.

* subversion/libsvn_client/merge.c

(filter_self_referential_mergeinfo, get_full_mergeinfo,

find_gaps_in_merge_source_history, calculate_left_hand_side):

Update some callers.

* subversion/libsvn_client/url.c

(svn_client_url_from_path): Create a wc context and update the call to

svn_client__derive_location().

(svn_client__derive_location): Fetch an entry without using an access baton.

Use scratch and result pools as appropriate.

* subversion/libsvn_client/ra.c

(svn_client__get_youngest_common_ancestor): Update caller.

* subversion/libsvn_client/mergeinfo.c

(svn_client__get_history_as_mergeinfo): Remove access baton parameter.

(svn_client_mergeinfo_log_merged, svn_client_mergeinfo_log_eligible):

Update callers.

* subversion/libsvn_client/mergeinfo.h

(svn_client__get_history_as_mergeinfo): Remove access baton and update docs.

  1. … 5 more files in changeset.
Remove another occurance of svn_wc__entry_versioned().

* subversion/libsvn_client/revisions.c

(svn_client__get_revision_number): Don't open an access baton to get an

entry, and adjust parameters to accept a wc context.

* subversion/libsvn_client/client.h

(svn_client__get_revision_number): Update docstring and params.

* subversion/libsvn_client/status.c,

subversion/libsvn_client/merge.c,

subversion/libsvn_client/prop_commands.c,

subversion/libsvn_client/ra.c,

subversion/libsvn_client/url.c,

subversion/libsvn_client/diff.c,

subversion/libsvn_client/copy.c,

subversion/libsvn_client/mergeinfo.c,

subversion/libsvn_client/blame.c,

subversion/libsvn_client/log.c,

subversion/libsvn_client/update.c:

Update callers to provide absolute paths and wc contexts to

svn_client__get_revision_number().

  1. … 12 more files in changeset.
Replace a single svn_wc__entry_versioned() call with

svn_wc__get_entry_versioned(),greatly simplify a couple of other functions

dependent on the first one, and update all their callers to stop passing

access batons around.

* subversion/libsvn_client/util.c

(wc_path_to_repos_url): Directly fetch an entry, instead of possibly opening

up an access baton to do it.

(svn_client__path_relative_to_root, svn_client_get_repos_root):

Don't use an access baton to call the above function, and greatly simplify

these functions by not worrying about cleaning up the access baton.

Also, add scratch_pools.

* subversion/libsvn_client/client.h

(svn_client__path_relative_to_root, svn_client_get_repos_root):

Update params and docstrings.

* subversion/libsvn_client/externals.c,

subversion/libsvn_client/cmdline.c,

subversion/libsvn_client/merge.c,

subversion/libsvn_client/url.c,

subversion/libsvn_client/copy.c,

subversion/libsvn_client/mergeinfo.c,

subversion/libsvn_client/list.c:

Update various callers of svn_client__path_relative_to_root() and

svn_client_get_repos_root().

  1. … 8 more files in changeset.
Relicense Subversion under the Apache License, Version 2.0.

* NOTICE: New.

* LICENSE: New.

* COPYING,

subversion/LICENSE: Remove.

* subversion/libsvn_subr/opt.c

(svn_opt__print_version_info): Note that the product as a whole is

copyrighted by the SVN Corp, and that it contains contributions from

many people, as referenced in NOTICE.

* subversion/bindings/swig/python/LICENSE_FOR_PYTHON_BINDINGS:

Relicense the SVN parts under Apache 2.0.

* everywhere:

Change copyright notices in file headers to reflect the Apache 2.0 license.

  1. … 882 more files in changeset.
Do the deprecation dance in libsvn_client.

* subversion/libsvn_client/switch.c,

subversion/libsvn_client/delete.c,

subversion/libsvn_client/export.c,

subversion/libsvn_client/revisions.c,

subversion/libsvn_client/merge.c,

subversion/libsvn_client/ra.c,

subversion/libsvn_client/url.c,

subversion/libsvn_client/checkout.c,

subversion/libsvn_client/locking_commands.c,

subversion/libsvn_client/cat.c,

subversion/libsvn_client/diff.c,

subversion/libsvn_client/copy.c,

subversion/libsvn_client/log.c,

subversion/libsvn_client/update.c:

More svn_dirent for svn_path function swaps.

  1. … 13 more files in changeset.
Don't cast away 'const' when there's a better way.

* subversion/libsvn_client/client.h,

subversion/libsvn_client/url.c

(svn_client__derive_location): Take a non-const session pointer, as it

requires, rather than pretending it takes a const one.

* subversion/libsvn_ra_svn/cyrus_auth.c

(svn_ra_svn__enable_sasl_encryption): Add "const" to the cast. Also move

variables into tighter scope.

* subversion/libsvn_subr/mergeinfo.c

(mergeinfo_to_stringbuf): Add "const" to the cast.

  1. … 3 more files in changeset.
Switch to use svn_wc_adm_close2()

* subversion/libsvn_wc/revision_status.c:

* subversion/libsvn_wc/util.c:

* subversion/libsvn_wc/adm_files.c:

* subversion/libsvn_wc/update_editor.c:

* subversion/libsvn_wc/tree_conflicts.c:

* subversion/libsvn_wc/copy.c:

* subversion/libsvn_wc/log.c:

* subversion/libsvn_client/relocate.c:

* subversion/libsvn_client/switch.c:

* subversion/libsvn_client/delete.c:

* subversion/libsvn_client/externals.c:

* subversion/libsvn_client/util.c:

* subversion/libsvn_client/revisions.c:

* subversion/libsvn_client/export.c:

* subversion/libsvn_client/status.c:

* subversion/libsvn_client/merge.c:

* subversion/libsvn_client/prop_commands.c:

* subversion/libsvn_client/ra.c:

* subversion/libsvn_client/url.c:

* subversion/libsvn_client/checkout.c:

* subversion/libsvn_client/revert.c:

* subversion/libsvn_client/locking_commands.c:

* subversion/libsvn_client/cat.c:

* subversion/libsvn_client/diff.c:

* subversion/libsvn_client/copy.c:

* subversion/libsvn_client/mergeinfo.c:

* subversion/libsvn_client/log.c:

* subversion/libsvn_client/changelist.c:

* subversion/libsvn_client/update.c:

* subversion/libsvn_client/resolved.c:

* subversion/libsvn_client/add.c:

* subversion/libsvn_client/commit.c:

(various): replace call to svn_wc_adm_close() with close2().

  1. … 31 more files in changeset.
Fix an uninitialized variable error.

Found by: Coverity <http://scan.coverity.com/>

(CID: 77)

* subversion/libsvn_client/url.c

(svn_client__derive_location): Initialize the cancelation function and baton

for the case where they aren't user provided.

Housekeeping: In the spirit of r27598, remove trailing whitespace in

our repository.

for extsn in c h cpp java py pl rb; do

find . -name "*.$extsn" | xargs perl -pi.bak -e 'next if /^\f$/; s/\s+$/\n/'

done

(This touches files in various and sundry parts of the tree, which I shan't

enumerate here.)

  1. … 175 more files in changeset.
Refactor URL and revnum resolution logic.

Note: Comprehensive commit message to come tomorrow; left it at the office.

  1. … 4 more files in changeset.
Expose a generic get-the-repository-root-path function.

* subversion/include/svn_client.h,

* subversion/libsvn_client/url.c

(svn_client_root_url_from_path): New (public wrapper around private

svn_client__get_repos_root).

  1. … 1 more file in changeset.