Checkout Tools
  • last updated 5 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates

Changeset 1614611 is being indexed.

Following the availability of apr_hash_this_key() etc. in APR v1.5, use

these in Subversion code instead of svn__apr_hash_index_key() etc. Provide

substitutes only when APR is too old to provide them.

* subversion/include/svn_types.h,

subversion/libsvn_subr/iter.c

(svn__apr_hash_index_key,

svn__apr_hash_index_klen,

svn__apr_hash_index_val):

Rename to apr_hash_this_key, apr_hash_this_key_len, apr_hash_this_val.

Declare and define them only if APR is older than 1.5.

Everywhere else: track the renames.

  1. … 102 more files in changeset.
Make 'svn lock' and 'svn unlock' obtain a working copy lock around its

operation. This resolves an old TODO in libsvn_wc and a user reported

issue involving readonly working copies.

* subversion/libsvn_client/locking_commands.c

(lock_baton): Add base_url.

(store_locks_callback): Update caller. Calculate a proper url for

notifications, instead of passing a relpath as url.

(wc_lock_item_t): Store url.

(organize_lock_targets): Obtain working copy locks if necessary. Calculate

targets per working copy.

(svn_client_lock,

svn_client_unlock): Update caller. Release working copy locks.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_add_lock2,

svn_wc_remove_lock2): Remove commented out validations.

* subversion/tests/cmdline/lock_tests.py

(lock_multi_wc,

commit_stolen_lock): Update assumptions for tweaked output.

* subversion/tests/cmdline/svnadmin_tests.py

(test_lslocks_and_rmlocks): Update assumptions for tweaked output.

  1. … 3 more files in changeset.
Don't canonicalize properties when doing a foreign copy.

Presumably if you're doing a foreign copy you don't have control over the

remote repo and you need to pull in whatever it has so as to be useful.

* subversion/include/svn_wc.h

(svn_wc_add_from_disk2): deprecate in favor of ...

(svn_wc_add_from_disk3): which lets you skip property canonicalization

* subversion/libsvn_wc/adm_ops.c

(svn_wc_add_from_disk2): Replace with ...

(svn_wc_add_from_disk3): new version of function with skip_checks arg.

* subversion/libsvn_wc/deprecated.c

(svn_wc_add_from_disk2): Deprecated function moved here.

* subversion/libsvn_client/copy_foreign.c

(ensure_added, file_close, svn_client__copy_foreign): Update

svn_wc_add_from_disk2() call to svn_wc_add_from_disk3() with TRUE

for skip_checks arg

(dir_change_prop, file_change_prop): Update comments to match new function

* subversion/libsvn_client/add.c

(add_file, add_dir_recursive, add): Update svn_wc_add_from_disk2() call to

svn_wc_add_from_disk3() with FALSE for the skip_checks arg

* subversion/libsvn/client/merge.c

(merge_dir_opened): ...

* subversion/libsvn/client/patch.c

(create_missing_parents, install_patched_target,

install_patched_prop_targets): ...

* subversion/tests/libsvn_wc/utils.c

(sbox_wc_add): ...

  1. … 7 more files in changeset.
Get rid of the ever increasing number of private apis in svn_sorts.h by adding

a new private/svn_sorts_private.h file with the private parts and updating the

needed #include-s.

*AND*

Improve error reporting during xml parsing in ra_serf a bit.

For 1.9 the number of private apis in this public header more than doubled,

doubling the original filesize, while our policy is to never add private

functions in public headers.

* build.conf

(libsvn_subr): Add export.

* subversion/include/private/svn_sorts_private.h

New file, copied from ../svn_sorts.h.

* subversion/include/svn_sorts.h

Remove everything possible in our private namespace. Keeping some

references.

* subversion/libsvn_client/diff_local.c

* subversion/libsvn_client/import.c

* subversion/libsvn_client/info.c

* subversion/libsvn_client/list.c

* subversion/libsvn_client/merge.c

* subversion/libsvn_client/mergeinfo.c

* subversion/libsvn_client/status.c

* subversion/libsvn_delta/compat.c

* subversion/libsvn_fs_fs/cached_data.c

* subversion/libsvn_fs_fs/index.c

* subversion/libsvn_fs_fs/low_level.c

* subversion/libsvn_fs_fs/pack.c

* subversion/libsvn_fs_fs/temp_serializer.c

* subversion/libsvn_fs_fs/transaction.c

* subversion/libsvn_fs_x/index.c

* subversion/libsvn_fs_x/low_level.c

* subversion/libsvn_fs_x/pack.c

* subversion/libsvn_fs_x/transaction.c

* subversion/libsvn_ra/compat.c

* subversion/libsvn_ra_serf/inherited_props.c

* subversion/libsvn_ra_serf/lock.c

* subversion/libsvn_repos/dump.c

* subversion/libsvn_repos/fs-wrap.c

* subversion/libsvn_subr/cmdline.c

* subversion/libsvn_subr/hash.c

* subversion/libsvn_subr/mergeinfo.c

* subversion/libsvn_subr/sorts.c

* subversion/libsvn_wc/adm_ops.c

* subversion/libsvn_wc/diff_editor.c

* subversion/libsvn_wc/status.c

* subversion/libsvn_wc/wc_db.c

* subversion/libsvn_wc/wc_db_update_move.c

* subversion/mod_dav_svn/repos.c

* subversion/svn/log-cmd.c

* subversion/svn/propget-cmd.c

* subversion/svnadmin/svnadmin.c

* subversion/svnlook/svnlook.c

* subversion/tests/libsvn_subr/priority-queue-test.c

* subversion/tests/libsvn_wc/op-depth-test.c

Fix includes.

* subversion/libsvn_ra_serf/util.c

(expat_response_handler): Combine XML errors with our custom parser errors

instead of only reporting one or the other.

  1. … 42 more files in changeset.
Remove a very obsolete wc_db api that was just a wrapper for

svn_wc__db_base_get_info() since far before 1.7.

* subversion/libsvn_wc/adm_files.c

(svn_wc__internal_ensure_adm): Update caller.

* subversion/libsvn_wc/adm_ops.c

(check_can_add_to_parent): Update caller.

(svn_wc_add4): Update caller.

* subversion/libsvn_wc/copy.c

(copy_or_move): Update caller.

* subversion/libsvn_wc/entries.c

(read_one_entry): Update caller.

* subversion/libsvn_wc/status.c

(get_repos_root_url_relpath): Update caller.

* subversion/libsvn_wc/update_editor.c

(make_dir_baton,

make_file_baton): Update caller.

(make_editor): Update caller.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_scan_base_repos): Remove function.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_scan_base_repos): Remove function.

  1. … 7 more files in changeset.
Fix the #include order such that svn_private_config.h is always

included first before any other svn header - if we also include

svn_hash.h.

* subversion/bindings/javahl/native/org_apache_subversion_javahl_ConfigImpl_Category.cpp,

subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c,

subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c,

subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c,

subversion/libsvn_auth_gnome_keyring/gnome_keyring.c,

subversion/libsvn_client/add.c,

subversion/libsvn_client/cat.c,

subversion/libsvn_client/changelist.c,

subversion/libsvn_client/cleanup.c,

subversion/libsvn_client/commit.c,

subversion/libsvn_client/commit_util.c,

subversion/libsvn_client/copy.c,

subversion/libsvn_client/copy_foreign.c,

subversion/libsvn_client/ctx.c,

subversion/libsvn_client/delete.c,

subversion/libsvn_client/deprecated.c,

subversion/libsvn_client/diff.c,

subversion/libsvn_client/diff_local.c,

subversion/libsvn_client/diff_summarize.c,

subversion/libsvn_client/export.c,

subversion/libsvn_client/externals.c,

subversion/libsvn_client/import.c,

subversion/libsvn_client/info.c,

subversion/libsvn_client/iprops.c,

subversion/libsvn_client/list.c,

subversion/libsvn_client/locking_commands.c,

subversion/libsvn_client/log.c,

subversion/libsvn_client/merge.c,

subversion/libsvn_client/mergeinfo.c,

subversion/libsvn_client/patch.c,

subversion/libsvn_client/prop_commands.c,

subversion/libsvn_client/ra.c,

subversion/libsvn_client/repos_diff.c,

subversion/libsvn_client/resolved.c,

subversion/libsvn_client/revert.c,

subversion/libsvn_client/status.c,

subversion/libsvn_client/switch.c,

subversion/libsvn_client/update.c,

subversion/libsvn_client/util.c,

subversion/libsvn_delta/compat.c,

subversion/libsvn_delta/xdelta.c,

subversion/libsvn_diff/parse-diff.c,

subversion/libsvn_diff/util.c,

subversion/libsvn_fs/access.c,

subversion/libsvn_fs_base/bdb/changes-table.c,

subversion/libsvn_fs_base/bdb/env.c,

subversion/libsvn_fs_base/dag.c,

subversion/libsvn_fs_base/fs.c,

subversion/libsvn_fs_base/lock.c,

subversion/libsvn_fs_base/revs-txns.c,

subversion/libsvn_fs_base/tree.c,

subversion/libsvn_fs_fs/caching.c,

subversion/libsvn_fs_fs/fs_fs.c,

subversion/libsvn_fs/fs-loader.c,

subversion/libsvn_fs_fs/lock.c,

subversion/libsvn_fs_fs/temp_serializer.c,

subversion/libsvn_fs_fs/tree.c,

subversion/libsvn_fs_util/fs-util.c,

subversion/libsvn_ra/compat.c,

subversion/libsvn_ra/deprecated.c,

subversion/libsvn_ra_local/ra_plugin.c,

subversion/libsvn_ra/ra_loader.c,

subversion/libsvn_ra_serf/blame.c,

subversion/libsvn_ra_serf/blncache.c,

subversion/libsvn_ra_serf/commit.c,

subversion/libsvn_ra_serf/getlocations.c,

subversion/libsvn_ra_serf/getlocationsegments.c,

subversion/libsvn_ra_serf/getlocks.c,

subversion/libsvn_ra_serf/inherited_props.c,

subversion/libsvn_ra_serf/log.c,

subversion/libsvn_ra_serf/merge.c,

subversion/libsvn_ra_serf/mergeinfo.c,

subversion/libsvn_ra_serf/options.c,

subversion/libsvn_ra_serf/property.c,

subversion/libsvn_ra_serf/replay.c,

subversion/libsvn_ra_serf/serf.c,

subversion/libsvn_ra_serf/update.c,

subversion/libsvn_ra_serf/util.c,

subversion/libsvn_ra_serf/xml.c,

subversion/libsvn_ra_svn/client.c,

subversion/libsvn_ra_svn/editorp.c,

subversion/libsvn_ra_svn/marshal.c,

subversion/libsvn_repos/authz.c,

subversion/libsvn_repos/commit.c,

subversion/libsvn_repos/delta.c,

subversion/libsvn_repos/deprecated.c,

subversion/libsvn_repos/fs-wrap.c,

subversion/libsvn_repos/hooks.c,

subversion/libsvn_repos/log.c,

subversion/libsvn_repos/replay.c,

subversion/libsvn_repos/reporter.c,

subversion/libsvn_repos/repos.c,

subversion/libsvn_repos/rev_hunt.c,

subversion/libsvn_subr/auth.c,

subversion/libsvn_subr/cmdline.c,

subversion/libsvn_subr/compat.c,

subversion/libsvn_subr/config_auth.c,

subversion/libsvn_subr/config.c,

subversion/libsvn_subr/deprecated.c,

subversion/libsvn_subr/dso.c,

subversion/libsvn_subr/hash.c,

subversion/libsvn_subr/io.c,

subversion/libsvn_subr/mergeinfo.c,

subversion/libsvn_subr/opt.c,

subversion/libsvn_subr/properties.c,

subversion/libsvn_subr/simple_providers.c,

subversion/libsvn_subr/sorts.c,

subversion/libsvn_subr/ssl_client_cert_providers.c,

subversion/libsvn_subr/ssl_client_cert_pw_providers.c,

subversion/libsvn_subr/ssl_server_trust_providers.c,

subversion/libsvn_subr/subst.c,

subversion/libsvn_subr/types.c,

subversion/libsvn_subr/username_providers.c,

subversion/libsvn_subr/utf.c,

subversion/libsvn_subr/win32_crypto.c,

subversion/libsvn_wc/adm_crawler.c,

subversion/libsvn_wc/adm_files.c,

subversion/libsvn_wc/adm_ops.c,

subversion/libsvn_wc/conflicts.c,

subversion/libsvn_wc/copy.c,

subversion/libsvn_wc/deprecated.c,

subversion/libsvn_wc/diff_editor.c,

subversion/libsvn_wc/diff_local.c,

subversion/libsvn_wc/entries.c,

subversion/libsvn_wc/externals.c,

subversion/libsvn_wc/info.c,

subversion/libsvn_wc/lock.c,

subversion/libsvn_wc/node.c,

subversion/libsvn_wc/old-and-busted.c,

subversion/libsvn_wc/props.c,

subversion/libsvn_wc/revert.c,

subversion/libsvn_wc/status.c,

subversion/libsvn_wc/translate.c,

subversion/libsvn_wc/update_editor.c,

subversion/libsvn_wc/upgrade.c,

subversion/libsvn_wc/wc_db.c,

subversion/libsvn_wc/wc_db_update_move.c,

subversion/libsvn_wc/wc_db_wcroot.c,

subversion/libsvn_wc/workqueue.c,

subversion/mod_dav_svn/activity.c,

subversion/mod_dav_svn/deadprops.c,

subversion/mod_dav_svn/lock.c,

subversion/mod_dav_svn/merge.c,

subversion/mod_dav_svn/mod_dav_svn.c,

subversion/mod_dav_svn/reports/update.c,

subversion/mod_dav_svn/repos.c,

subversion/mod_dav_svn/version.c,

subversion/svnadmin/svnadmin.c,

subversion/svnauth/svnauth.c,

subversion/svn/cl-conflicts.c,

subversion/svn/commit-cmd.c,

subversion/svn/conflict-callbacks.c,

subversion/svn/diff-cmd.c,

subversion/svn/help-cmd.c,

subversion/svnlook/svnlook.c,

subversion/svnmucc/svnmucc.c,

subversion/svn/notify.c,

subversion/svn/propedit-cmd.c,

subversion/svn/propget-cmd.c,

subversion/svn/props.c,

subversion/svnrdump/dump_editor.c,

subversion/svnrdump/svnrdump.c,

subversion/svnrdump/util.c,

subversion/svnserve/serve.c,

subversion/svn/status.c,

subversion/svn/status-cmd.c,

subversion/svn/svn.c,

subversion/svnsync/svnsync.c,

subversion/svnsync/sync.c,

subversion/svn/util.c,

subversion/tests/libsvn_fs/fs-test.c,

subversion/tests/libsvn_repos/repos-test.c,

subversion/tests/libsvn_subr/hashdump-test.c,

subversion/tests/libsvn_subr/mergeinfo-test.c,

subversion/tests/libsvn_subr/subst_translate-test.c,

subversion/tests/libsvn_wc/conflict-data-test.c,

subversion/tests/libsvn_wc/op-depth-test.c,

subversion/tests/libsvn_wc/wc-test.c,

subversion/tests/svn_test_fs.c,

tools/dev/fsfs-reorg.c,

tools/server-side/fsfs-stats.c): #include svn_private_config.h first

  1. … 180 more files in changeset.
Fix issue #4364: Correctly remove the stale entries from the lock table when

committing deletions.

* subversion/libsvn_client/commit.c

(post_process_commit_item): always pass the flag to remove locks for deleted

and replaced items.

* subversion/libsvn_wc/wc-queries.sql

Add a new query which removes all lock rows recursively for a node.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_base_remove): Add a new parameter remove_locks to recursively

remove the lock rows.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_base_remove): Forward the new remove_locks parameter to

db_base_remove.

(db_base_remove): Add and implement remove_locks.

(commit_node): Also remove the locks recursively for subnodes of the

current node.

(bump_node_revision): Pass FALSE for remove_locks to get the old default

behaviour.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): In the shortcut for deleted nodes, pass TRUE to

remove the locks recursively.

* subversion/libsvn_wc/crop.c

(crop_children): Pass FALSE for remove_locks to get the old default

behaviour.

* subversion/libsvn_wc/externals.c

(svn_wc__external_remove): Pass FALSE for remove_locks to get the old

default behaviour.

* subversion/libsvn_wc/update_editor.c

(delete_entry

close_edit): Pass FALSE for remove_locks to get the old default behaviour.

* subversion/libsvn_wc/workqueue.c

(run_base_remove): Pass FALSE for remove_locks to get the old default

behaviour.

* subversion/tests/libsvn_wc/op-depth-test.c

(base_dir_insert_remove): Pass FALSE for remove_locks to get the old default

behaviour.

* subversion/tests/cmdline/lock_tests.py

(def drop_locks_on_parent_deletion): Provide a regression test which catches

reappearing locks.

Patch by: Markus Schaber <m.schaber{_AT_}codesys.com>

(minor tweaks by me)

  1. … 10 more files in changeset.
Significantly reduce the number of open files during a typical update

over ra_serf by using lazy-opening streams to delay opening until the

HTTP response is received. This changes the new-in-1.8 lazy-open API.

* subversion/include/svn_io.h

(svn_stream_lazyopen_create): Add open_on_close boolean parameter.

* subversion/libsvn_subr/stream.c

(struct lazyopen_baton_t): Add open_on_close boolean member.

(close_handler_lazyopen): Open if required.

(svn_stream_lazyopen_create): Add open_on_close boolean parameter.

* subversion/libsvn_wc/update_editor.c

(lazy_open_source, lazy_open_target, struct lazy_target_baton): New.

(apply_textdelta): Use lazy-open streams for source and target.

* subversion/libsvn_wc/adm_ops.c

(svn_wc__get_pristine_contents_by_checksum): Adjust call.

  1. … 3 more files in changeset.
* **/**

Run tools/dev/remove-trailing-whitespace.sh to remove all trailing whitespace

before we branch 1.8, like we did before creating previous branches.

No functional changes.

  1. … 199 more files in changeset.
Use svn_hash_gets and svn_hash_puts.

* subversion/libsvn_wc/adm_crawler.c

* subversion/libsvn_wc/adm_ops.c

* subversion/libsvn_wc/conflicts.c

* subversion/libsvn_wc/copy.c

* subversion/libsvn_wc/deprecated.c

* subversion/libsvn_wc/diff_local.c

* subversion/libsvn_wc/entries.c

* subversion/libsvn_wc/externals.c

* subversion/libsvn_wc/info.c

* subversion/libsvn_wc/old-and-busted.c

* subversion/libsvn_wc/props.c

* subversion/libsvn_wc/revert.c

* subversion/libsvn_wc/status.c

* subversion/libsvn_wc/translate.c

* subversion/libsvn_wc/update_editor.c

* subversion/libsvn_wc/upgrade.c

* subversion/libsvn_wc/wc_db.c

* subversion/libsvn_wc/wc_db_update_move.c

* subversion/libsvn_wc/wc_db_wcroot.c

* subversion/libsvn_wc/workqueue.c

  1. … 19 more files in changeset.
Following r1459058, include the necessary header to make the build work with

APR < 1.3.0.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_process_committed_queue2): Include 'svn_dep_compat.h'.

* subversion/svn/notify.c

(svn_cl__notifier_reset_conflict_stats): Same.

* subversion/svnrdump/dump_editor.c

(do_dump_props, close_directory, close_file): Same.

  1. … 2 more files in changeset.
Make a compatibility macro for 'apr_hash_clear()', to be used when APR <

1.3.0, similar to the compatibility macro 'apr_array_clear' that we already

have for the same reason, so that we can use it regardless of which APR we

compile against. Call apr_hash_clear() instead of svn_hash__clear(),

everywhere (that is, in a grand total of four files).

Change the signature of svn_hash__clear() to match apr_hash_clear() and use

it to implement the compatibility macro. It now uses the hash's own private

iterator (which we don't generally use in Subversion), like APR's

apr_hash_clear() does.

* subversion/include/private/svn_subr_private.h

(svn_hash__clear): Remove this declaration.

* subversion/include/private/svn_dep_compat.h

(svn_hash__clear): Declare (the new signature) when APR < 1.3.0.

(apr_hash_clear): New macro, when APR < 1.3.0; calls svn_hash__clear.

* subversion/libsvn_subr/hash.c

(svn_hash__clear): Remove the pool argument, and return void.

* subversion/libsvn_ra_serf/serf.c

(svn_ra_serf__get_dir): Call apr_hash_clear() instead of svn_hash__clear().

* subversion/libsvn_wc/adm_ops.c

(svn_wc_process_committed_queue2): Same.

* subversion/svn/notify.c

(svn_cl__notifier_reset_conflict_stats): Same.

* subversion/svnrdump/dump_editor.c

(do_dump_props, close_directory, close_file): Same.

  1. … 6 more files in changeset.
Merge svn_kind_t into svn_node_kind_t, leaving only one public enumeration

that describes node kinds.

* subversion/include/svn_types.h (svn_kind_t): Removed.

All uses of svn_kind_t were replaced with svn_node_kind_t.

(svn_node_kind_t): New enumeration constant, svn_node_symlink.

Replaces all previous uses of svn_kind_symlink.

(svn__node_kind_from_kind): Removed. All call sites updated.

(svn__kind_from_node_kind): Removed. All call sites updated.

* subversion/libsvn_wc/tree_conflicts.c (node_kind_map):

Added comment about incompatible representation of svn_node_unknown.

* subversion/libsvn_wc/node.c (convert_db_kind_to_node_kind):

May be redundant, and comment is out of date. Added a note about that.

There are also a zillion changes in dependent files, and they all result

from the following renames:

svn_kind_t to svn_node_kind_t

svn_kind_none to svn_node_none

svn_kind_file to svn_node_file

svn_kind_dir to svn_node_dir

svn_kind_unknown to svn_node_unknown

svn_kind_symlink to svn_node_symlink

  1. … 65 more files in changeset.
Add a new svn_wc__db_scan_moved() function based on the internal scan_added()

which allows access to a bit more information. Use this information to fix

a case where a specific move could never be committed.

* subversion/libsvn_wc/adm_files.c

(svn_wc__internal_ensure_adm): Update caller.

* subversion/libsvn_wc/adm_ops.c

(check_can_add_to_parent): Update caller.

* subversion/libsvn_wc/copy.c

(copy_or_move): Update caller.

* subversion/libsvn_wc/entries.c

(get_info_for_deleted,

read_one_entry): Update caller.

* subversion/libsvn_wc/info.c

(build_info_for_node): Update caller. Only read moved_from for

op-roots, like how we handle copies.

* subversion/libsvn_wc/node.c

(svn_wc__internal_get_repos_info): Update caller.

(svn_wc__internal_get_origin): Update caller.

(svn_wc__node_was_moved_here): Use new api.

* subversion/libsvn_wc/status.c

(read_info): Use different output argument of svn_wc__db_scan_addition.

(assemble_status): Reduce scope of err. Use new api for obtaining moved

from information.

* subversion/libsvn_wc/update_editor.c

(check_tree_conflict,

add_directory,

add_file): Update caller.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_scan_addition): Remove two arguments. Tell implementation which

arguments are not needed to avoid additional queries in generic cases.

(svn_wc__db_scan_moved): New function.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_scan_addition): Remove moved_from handling additional

information as no api user is really depending on it.

(svn_wc__db_scan_moved): New function.

* subversion/tests/libsvn_wc/db-test.c

(test_scan_addition): Update caller. Also call svn_wc__db_scan_moved.

* subversion/tests/libsvn_wc/op-depth-test.c

(nested_move_commit): Use new api.

(test_funcs): Remove XFail from commit_moved_descendant.

  1. … 11 more files in changeset.
Resolve issue #4304, by detecting some kinds of shadowed nodes before trying to

set a file read only.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_remove_lock2): Handle invalid status err.

* subversion/tests/cmdline/lock_tests.py

(lock_unlock_deleted): Remove XFail marker.

  1. … 1 more file in changeset.
* subversion/libsvn_wc/adm_ops.c

(svn_wc_add_lock2,

svn_wc_remove_lock2): Add disabled write check, as the callers are currently

not properly obtaining a lock.

Extract the delete and revert code from adm_ops.h and place it in specific

files. They don't share any static functions with the rest of the code there.

No functional changes.

* subversion/libsvn_wc/adm_ops.c

(includes): Remove now unused includes.

(erase_unversioned_from_wc,

create_delete_wq_items,

svn_wc__delete_many,

svn_wc__delete_internal,

svn_wc_delete4): Move to delete.c

(remove_conflict_file,

compare_revert_list_copied_children,

revert_restore_handle_copied_dirs,

revert_restore,

svn_wc__revert_internal,

revert_changelist,

revert_partial,

svn_wc_revert4): Move to revert.c

(svn_wc__internal_remove_from_revision_control,

remove_from_revision_status_callback,

svn_wc_remove_from_revision_control2): Move to delete.c

* subversion/libsvn_wc/delete.c

(includes): Remove now unused includes.

(erase_unversioned_from_wc,

create_delete_wq_items,

svn_wc__delete_many,

svn_wc__delete_internal,

svn_wc_delete4,

svn_wc__internal_remove_from_revision_control,

remove_from_revision_status_callback,

svn_wc_remove_from_revision_control2): Remove all functions except these.

* subversion/libsvn_wc/revert.c

(includes): Remove now unused includes.

(remove_conflict_file,

compare_revert_list_copied_children,

revert_restore_handle_copied_dirs,

revert_restore,

svn_wc__revert_internal,

revert_changelist,

revert_partial,

svn_wc_revert4): Remove all functions except these.

  1. … 2 more files in changeset.
Following up on my previous issue #4288 fix, and the recent test extension in

r1432612, resolve the rest of issue #4288 which appears to be invisible on

Windows.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): Update caller.

* subversion/libsvn_wc/crop.c

(crop_children): Update caller. Pass the right path.

* subversion/libsvn_wc/externals.c

(svn_wc__external_remove): Update caller.

* subversion/libsvn_wc/update_editor.c

(delete_entry): Ask svn_wc__db_base_remove() not to queue deletes if the

node or one of its ancestors is shadowed or obstructed.

* subversion/libsvn_wc/wc_db.c

(db_base_remove,

svn_wc__db_base_remove): Make queueing wq items for deletes optional.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_base_remove): Add argument and update documentation.

* subversion/libsvn_wc/workqueue.c

(run_base_remove): Update caller.

* subversion/tests/libsvn_wc/op-depth-test.c

(base_dir_insert_remove): Update caller.

  1. … 7 more files in changeset.
Expose revert_internal() from libsvn_wc/adm_ops.c to other libsvn_wc files.

* subversion/libsvn_wc/adm_ops.c

(revert_internal): Drop 'static', and rename to ...

(svn_wc__revert_internal): ... this.

(revert_changelist, revert_partial, svn_wc_revert4): Update callers.

* subversion/libsvn_wc/wc.h

(svn_wc__revert_internal): Declare.

  1. … 1 more file in changeset.
Per discussion on IRC, and in compliance with one of the suggestions

found at http://subversion.tigris.org/issues/show_bug.cgi?id=3348#desc10,

revert the changes (r1159286, r1159299, and r1160691) which caused the

empty-string changelist name (as applied to the --changelist option)

to be specially handled.

  1. … 4 more files in changeset.
Teach some WC and client 'add' functions to take the properties as a

parameter so that the whole addition including any properties can be done

all at once. This makes 'svn add' into a single DB operation per node and

makes the APIs ready for similar usage by code such as merge and patch.

* subversion/libsvn_client/add.c

(add_file): Simplify greatly by passing the props to svn_wc_add_from_disk()

instead of adding them one by one afterwards and trying to revert the

add if that fails. Delegate sending the notification too.

(add_dir_recursive, add): Track the API changes.

* subversion/libsvn_client/patch.c

(create_missing_parents,

install_patched_target,

install_patched_prop_targets): Track the API changes.

* subversion/include/svn_wc.h

(svn_wc_add_from_disk2): New revision of svn_wc_add_from_disk(), taking a

'props' parameter.

(svn_wc_add_from_disk): Deprecate.

* subversion/libsvn_wc/adm_ops.c

(add_from_disk): Take a 'props' parameter, pass them on, and install and

run a work queue item if necessary to set the on-disk executable and

read-only bits.

(svn_wc_add4): Track the API changes.

(svn_wc_add_from_disk2): Rename from 'svn_wc_add_from_disk'. Take a new

'props' parameter, check and canonicalize the props, and pass them on.

Adjust the notification to include the value of any mime-type property,

as that is what libsvn_client used to do.

* subversion/libsvn_wc/deprecated.c

(svn_wc_add_from_disk): New function, wrapping svn_wc_add_from_disk2().

* subversion/libsvn_wc/props.h

(svn_wc__canonicalize_props): New function.

* subversion/libsvn_wc/props.c

(ensure_prop_is_regular_kind, svn_wc__canonicalize_props): New functions.

* subversion/libsvn_wc/wc_db.h,

subversion/libsvn_wc/wc_db.c

(svn_wc__db_op_add_directory,

svn_wc__db_op_add_file,

svn_wc__db_op_add_symlink): Take a 'props' parameter and pass it on.

* subversion/tests/libsvn_wc/conflict-data-test.c

(test_read_write_tree_conflicts): Track the API changes.

* subversion/tests/libsvn_wc/utils.c

(sbox_wc_add): Track the API changes.

  1. … 10 more files in changeset.
* subversion/libsvn_wc/adm_ops.c

(revert_restore): Fix typo. No functional changes.

Resolve issue #4168, by detecting working copy roots when handling the final

step of reverts.

* subversion/libsvn_wc/adm_ops.c

(revert_restore): Add revert_root argument and detect obstructing working

copies if not reverting explicit targets. Update recursion

(revert_internal): Update caller.

* subversion/tests/cmdline/revert_tests.py

(revert_obstructing_wc): Update expected result.

  1. … 1 more file in changeset.
* subversion/libsvn_wc/adm_ops.c

(add_from_disk): Remove unused notification parameters.

(svn_wc_add4, svn_wc_add_from_disk): Adjust callers.

Standardize the naming of the recorded size and time variable names.

No functional changes.

* subversion/libsvn_wc/adm_ops.c

(revert_restore): Rename local variable.

* subversion/libsvn_wc/entries.c

(db_node_t): Rename variables in struct.

(insert_node,

write_entry): Update users.

* subversion/libsvn_wc/props.c

(do_propset): Update comment.

* subversion/libsvn_wc/status.c

(read_info,

assemble_status): Update struct usage.

* subversion/libsvn_wc/update_editor.c

(svn_wc_add_repos_file4): Update comment.

* subversion/libsvn_wc/wc_db.c

(read_info): Rename argument in prototype.

(insert_base_node): Rename variable.

(record_baton_t): Add comment. Use proper variable names.

(db_record_fileinfo,

svn_wc__db_global_record_fileinfo,

set_props_txn): Update baton usage.

(remove_node_txn): Rename variable.

(read_info,

svn_wc__db_read_info_internal,

svn_wc__db_read_info): Rename argument.

(read_children_info): Update struct usage.

(has_local_mods): Rename variable.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_read_info): Rename argument and update documentation.

(svn_wc__db_info_t): Rename variable.

(svn_wc__db_global_record_fileinfo): Rename arguments and update

documentation.

* subversion/libsvn_wc/workqueue.h

(svn_wc__wq_build_file_install): Update documentation.

* subversion/tests/libsvn_wc/db-test.c

(test_working_info): Rename a few variables.

  1. … 8 more files in changeset.
Make the wc_db property handling code report an error when accessing

properties on deleted (and hidden) nodes, when not explicitly asking for

the pristine properties.

This change will (in a followup commit) allow removing some expensive checks

in higher level apis.

* subversion/libsvn_client/add.c

(svn_client__get_all_ignores): Handle getting the error

SVN_ERR_WC_PATH_UNEXPECTED_STATUS as if touching an unversioned

path.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_add_lock2): When a node doesn't have properties, we can assume

it doesn't need svn:needs-lock special handling.

* subversion/libsvn_wc/wc_db.c

(db_read_pristine_props): Add argument.

(cross_db_copy,

set_props_txn,

db_read_props): Update callers. Expect errors when reading deleted nodes.

(db_read_pristine_props): Add boolean argument to trigger reading while

in an unexpected state errors.

(svn_wc__db_read_pristine_props): Update caller. Suppress deleted node

errors.

  1. … 2 more files in changeset.
Check for the required write lock in another WC function.

* subversion/include/svn_wc.h

(svn_wc_remove_from_revision_control2): In the doc string, state exactly

what write lock is required.

* subversion/libsvn_wc/adm_ops.c

(svn_wc__internal_remove_from_revision_control): Check for the write lock.

  1. … 1 more file in changeset.
Disable automatic working copy upgrades. This has been discussed over and

over, with many people in the community indicating they prefer manual upgrades.

For now, this is a hard-coded default. There is no way to enable auto-upgrade.

And unfortunately there is no single knob to globally switch auto-upgrade on

and off in the code. Rather, function parameters have to be tweaked in various

places where a working copy database is opened.

Some parts of the upgrade code were written and tested exclusively for

upgrading from 1.6 and earlier working copy formats to wc-ng, and thus

needed small fixes to allow 'svn upgrade' to run wc-ng -> wn-ng format

bumps without crashing.

* subversion/libsvn_wc/adm_files.c

(svn_wc_create_tmp_file2): Don't auto-upgrade working copies.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_get_pristine_copy_path): Don't auto-upgrade working copies.

* subversion/libsvn_wc/cleanup.c

(svn_wc_cleanup3): Don't auto-upgrade working copies.

* subversion/libsvn_wc/context.c

(svn_wc_context_create): Don't auto-upgrade working copies.

* subversion/libsvn_wc/lock.c

(pool_cleanup_locked, svn_wc_adm_open3, svn_wc_adm_probe_open3,

open_anchor): Don't auto-upgrade working copies.

* subversion/libsvn_wc/upgrade.c

(svn_wc__upgrade_sdb): Initialise *result_format before use if the

working copy is already at format SVN_WC__VERSION to prevent an assertion

during no-op upgrades of wc-ng working copies.

(is_old_wcroot): Remove Subversion version numbers from error messages.

It is now misleading to say that an upgrade is not possible because a

pre-1.7 working copy was found since 'svn upgrade' now runs on any format.

(svn_wc_upgrade): Handle upgrades from wc-ng-style working copies.

Enable auto-upgrade of the db during upgrades from pre-1.7 WCs to avoid

'svn upgrade' advising users to run 'svn upgrade'.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_bump_format): New helper function for wc-ng -> wc-ng upgrades.

Ensures that the upgrade target is a working copy root, and performs a

format bump of wcroot->sdb, which isn't exposed outside of the wc_db layer.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_bump_format): Declare.

* subversion/libsvn_wc/wc_db_wcroot.c

(svn_wc__db_pdh_create_wcroot): Properly handle the case where we do not

auto-upgrade and run into a working copy using an older format.

Previously, we ended up asserting in VERIFY_USABLE_WCROOT() somewhere

because no upgrade happened but no error was returned either. Instead,

return an error advising the user to upgrade the working copy.

* subversion/tests/cmdline/upgrade_tests.py

(wc_is_too_old_regex): The error message matched by this regex has changed

in some cases, so adjust the regex accordingly.

(basic_upgrade): Expect slightly different error messages resulting from

above changes. The error code returned is unchanged, however.

(upgrade_tree_conflict_data, upgrade_from_format_28): These tests were

running 'svn status' and 'svn info' to trigger auto-upgrades. Make them

run 'svn upgrade' instead to keep them passing.

  1. … 9 more files in changeset.
Avoid a parsing order dependency in the add symlink code. This might fix a

symlink issue on *nix operating systems.

* subversion/libsvn_wc/adm_ops.c

(check_can_add_node): Allow adding symlinks pointing to a working copy to

their parent directories.

* subversion/libsvn_wc/adm_ops.c

(create_delete_wq_items): Pass scratch and result pools in correct order.