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

Changeset 1159286 is being indexed.

*** THIS CHANGE REVERTED IN r1428585 ***

Fix issue #3348, 'Provide syntax which means "include all files not in a

changelist"'.

[ Question: why is filtering done twice, both in adm_ops.c and in status.c? ]

* subversion/libsvn_wc/adm_ops.c

(svn_wc__internal_changelist_match):

Special case the empty changelist name as "not in a changelist".

* subversion/libsvn_client/status.c

(tweak_status):

Special case the empty changelist name as "not in a changelist".

* subversion/tests/cmdline/changelist_tests.py

(empty_pseudo_changelist): New test.

(test_list): Run it.

* subversion/svn/main.c

(main):

Drop a validation which is already done by

svn_client_add_to_changelist() and is now bogus.

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

(revert_restore): Do not use uninitialised variables if read_info() throws

a path-not-found error and we are dealing with the revert of a copy.

Should fix random failures of revert_test 19 on various buildbots.

(Thanks for testing, danielsh!)

* subversion/libsvn_wc/adm_ops.c

(revert_restore_handle_copied_dirs): Replace the output parameter NEW_KIND

with a new boolean output parameter REMOVED_SELF. This ensures that the

node kind variable the caller is using remains correct in all cases, and

makes the code a bit easier to follow.

(revert_restore): Update caller.

* subversion/libsvn_wc/adm_ops.c

(revert_restore_handle_copied_dirs): Don't ignore all errors returned by

svn_io_dir_remove_nonrecursive(). Ignore only the ones we care about.

Use svn_io_dir_remove_nonrecursive() to remove LOCAL_ABSPATH itself. This

will check for remaining children so this function doesn't need to run

the check itself.

Suggested by: rhuijben

Make 'svn revert' remove any kind of copied file, regardless of whether

the file was modified post-copy.

The rationale for this change can be found in a comment by Julian Foad

on issue #3601: http://subversion.tigris.org/issues/show_bug.cgi?id=3101#desc6

Quote:

svn revert should undo the local text and prop changes, undo the scheduling,

and also undo the copying of the file into its new location on disk,

since that is (like prop changes) an operation that Subversion performed

on the user's behalf as a "local modification" of the user's working copy.

Most parts of this change are concerned with removing the pristine checksum

comparison revert_restore_handle_copied_file() was doing. A fix for a bug

in revert_list_read() uncovered by a failing test is also included.

* subversion/tests/cmdline/copy_tests.py

(remove_conflict_file): No need to remove 'pi' after revert.

* subversion/tests/cmdline/revert_tests.py

(revert_tree_conflicts_in_updated_files): Expect 'A/D/G/rho' to be

delete from disk after revert. No need to delete it manually.

* subversion/libsvn_wc/adm_ops.c

(revert_restore_handle_copied_file): Remove. This was wrapping the

comparison to the pristine file, which is now unnecessary.

(revert_restore_handle_copied_dirs, revert_restore): Remove all reverted

copied files from disk. Update some comments.

* subversion/libsvn_wc/wc-queries.sql

(revert_list, trigger_revert_list_nodes, STMT_SELECT_REVERT_LIST,

STMT_SELECT_REVERT_LIST_COPIED_CHILDREN): Drop the pristine CHECKSUM.

It isn't needed anymore.

* subversion/libsvn_wc/wc_db.c

(revert_list_read_baton): Remove PRISTINE_CHECKSUM.

(revert_list_read): Remove handling of the pristine checksum.

Fix a bug: The COPIED_HERE output parameter wasn't set correctly if a

copied node also had an entry in the ACTUAL_NODES table. E.g. a copied

node which was also a tree-conflict victim was not recognised as a copy

by the revert code, and left behind unversioned on disk. Set COPIED_HERE

correctly in this case, too.

(svn_wc__db_revert_list_read): Remove PRISTINE_CHECKSUM output parameter.

(revert_list_read_copied_children): Remove handling of the pristine checksum.

Small indentation fixes.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_revert_list_read): Remove PRISTINE_CHECKSUM output parameter.

(svn_wc__db_revert_list_copied_child_info_t): Remove PRISTINE_CHECKSUM.

  1. … 5 more files in changeset.
Remove reverted copied files and directories from disk, if they weren't

modified after being copied.

To achieve this we add more columns to rows in the revert list:

the node kind, the repos_id (which is not NULL for copies),

the op_root, and, if the node is a file, the pristine checksum.

While restoring the BASE on-disk state, process nodes in the revert list

marked as copies in a special way: Compare reverted copied files with

their pristines, and remove the ones that match from disk. Next, remove

any reverted copied directories which are left empty as a result.

This commit addresses issues #3101 and #876, and my own annoyance at

unversioned things left behind in my testing WCs (been testing 'svn move'

with subsequent 'revert' a lot lately).

We could take this further and remove copied files which were modified

post-copy (after all, we also destroy textual modifications to files which

were not copied). But that's a decision for another day.

Review by: julianfoad

* subversion/tests/cmdline/merge_tests.py

(merge_away_subtrees_noninheritable_ranges): No longer need to remove

unversioned files after revert.

* subversion/tests/cmdline/depth_tests.py

(excluded_path_misc_operation): No longer need to remove unversioned files

after revert.

* subversion/tests/cmdline/revert_tests.py

(status_of_missing_dir_after_revert_replaced_with_history_dir): No longer

need to remove unversioned files. And don't expect them in status output.

* subversion/libsvn_wc/adm_ops.c

(revert_restore_handle_copied_file, revert_restore_handle_copied_dirs,

compare_revert_list_copied_children): New.

(revert_restore): When reverting copies, remove their remains from disk,

except for files which were modified after being copied, and directories

that contain unversioned files.

* subversion/libsvn_wc/wc-queries.sql

(revert_list): Add new columns OP_DEPTH, REPOS_ID, KIND, CHECKSUM.

Copy values from rows deleted from the NODES table into them.

Nothing changes for actual-only nodes.

(STMT_SELECT_REVERT_LIST): Get the new columns.

(STMT_SELECT_REVERT_LIST_COPIED_CHILDREN): New statement which returns

all copied children within a given reverted local_relpath.

* subversion/libsvn_wc/wc.h

(svn_wc__compare_file_with_pristine): Declare.

* subversion/libsvn_wc/questions.c

(compare_and_verify): Renamed to ...

(svn_wc__compare_file_with_pristine): ... this, so the revert code can

access this function. No modifications were made to the implementation.

(svn_wc__internal_file_modified_p): Track above function rename.

* subversion/libsvn_wc/wc_db.c

(revert_list_read_baton): Add COPIED_HERE, KIND, and PRISTINE_CHECKSUM.

(revert_list_read): Populate the new baton fields.

(svn_wc__db_revert_list_read): Add COPIED_HERE, KIND, and PRISTINE_CHECKSUM

output parameters.

(revert_list_read_copied_children_baton): New.

(revert_list_read_copied_children): New. Returns a list of all copied

children which existed within a reverted subtree.

(svn_wc__db_revert_list_read_copied_children): Exposes the

revert_list_read_copied_children() function, wrapping it in an sqlite

transaction.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_revert_list_read): Declare new output parameters COPIED_HERE,

KIND, and PRISTINE_CHECKSUM. Update docstring.

(svn_wc__db_revert_list_copied_child_info_t): New.

(svn_wc__db_revert_list_read_copied_children): Declare.

  1. … 8 more files in changeset.
Make svn_wc__db_scan_addition() provide information about the local source

of a move for nodes with a 'moved-here' status.

Some future callers will only want to act on the op-roots involved in

a move, e.g. the commit code detecting whether both halfs of a move

are among the commit targets.

Other future callers might want to act directly on children of the op-roots,

e.g. code performing automatic tree conflict resolution.

So scan_addition() provides both the moved_from abspath and the abspath of

the operation root of the delete-half of the move. This should satisfy

either use case to some degree. It might not be the optimal solution

for all use cases but won't hurt, either.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_scan_addition, scan_addition): New output parameters

MOVED_FROM_ABSPATH and DELETE_OP_ROOT_ABSPATH.

(get_moved_from_info): New helper function which computes values for

above new output parameters.

(scan_addition_baton_t): Add MOVED_FROM_ABSPATH and DELETE_OP_ROOT_ABSPATH.

(scan_addition_txn): Run get_moved_from_info() for 'moved-here' nodes.

(get_info_for_copy, read_url_txn, svn_wc__db_global_relocate): Update

scan_addition() calls.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_scan_addition): Update declaration and docstring.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_MOVED_FROM_RELPATH): New query which selects the 'moved-from'

path corresponding to a 'moved-here' node.

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

(TESTING_DATA): Create another row for the delete-half of a move.

svn_wc__db_scan_addition() now treats a move without a delete-half

as if it was a normal a copy. (We've been recording delete-halfs

since r1151166.)

(test_scan_addition): Check for moved-from information scan_addition()

now returns for 'moved-here' nodes.

The remaining items list updated callers of svn_wc__db_scan_addition().

All of them pass NULL for the new output parameters.

* subversion/libsvn_wc/props.c

(svn_wc__get_pristine_props): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/adm_ops.c

(check_can_add_to_parent): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/adm_crawler.c

(svn_wc_restore, report_revisions_and_depths,

svn_wc_crawl_revisions5): Update svn_wc__db_scan_addition() calls.

* subversion/libsvn_wc/diff_local.c

(file_diff): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/diff_editor.c

(file_diff, report_wc_file_as_added,

close_file): Update svn_wc__db_scan_addition() calls.

* subversion/libsvn_wc/adm_files.c

(svn_wc__internal_ensure_adm): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/update_editor.c

(create_tree_conflict, add_directory,

add_file): Update svn_wc__db_scan_addition() calls.

* subversion/libsvn_wc/info.c

(build_info_for_node): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/copy.c

(copy_or_move): Update svn_wc__db_scan_addition() calls.

* subversion/libsvn_wc/status.c

(get_repos_root_url_relpath): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/lock.c

(child_is_disjoint): Update svn_wc__db_scan_addition() call.

* subversion/libsvn_wc/entries.c

(get_info_for_deleted,

read_one_entry): Update svn_wc__db_scan_addition() calls.

* subversion/libsvn_wc/node.c

(svn_wc__internal_get_repos_info, svn_wc__node_get_repos_relpath,

svn_wc__internal_get_copyfrom_info, svn_wc__internal_get_commit_base_rev,

svn_wc__internal_get_origin): Update svn_wc__db_scan_addition() calls.

  1. … 16 more files in changeset.
Rename the new_revert_* functions to just revert_*. It is confusing

to have functions called new_something when the old implementation

is already obsolete (as of r1088811).

* subversion/libsvn_wc/adm_ops.c

(new_revert_internal, new_revert_changelist,

new_revert_partial): Rename to ...

(revert_internal, revert_changelist, revert_partial): ... these, respectively.

(svn_wc_revert4): Update caller.

Record moved-to information at the delete-half of a move.

* subversion/include/private/svn_wc_private.h

(svn_wc__delete_internal): Declare.

* subversion/libsvn_wc/adm_ops.c

(svn_wc__delete_internal): New. This is like svn_wc_delete4() but has

one additional parameter MOVED_TO_ABSPATH. If not NULL, this indicates

that the delete is the delete-half of a move.

(svn_wc_delete4): Reimplement as a wrapper around svn_wc__delete_internal().

* subversion/libsvn_wc/wc-queries.sql

(STMT_INSERT_DELETE_FROM_NODE_RECURSIVE): Adjust to only insert children

of the node being deleted.

(STMT_INSERT_DELETE_NODE): New. This statement deletes a single node,

and allows populating the moved_to column in NODES.

* subversion/libsvn_wc/copy.c

(svn_wc_move): Call svn_wc__delete_internal() with a MOVED_TO_ABSPATH

instead of calling svn_wc_delete4().

* subversion/libsvn_wc/wc_db.c

(op_delete_baton_t): Add new field MOVED_TO_RELPATH.

(op_delete_txn): Use STMT_INSERT_DELETE_NODE to delete LOCAL_ABSPATH

itself, and possibly mark LOCAL_ABSPATH has having been moved elsewhere.

Use STMT_INSERT_DELETE_FROM_NODE_RECURSIVE to delete children of

LOCAL_ABSPATH (before, this statement was also used to delete LOCAL_ABSPATH

itself).

(svn_wc__db_op_delete): New parameter MOVED_TO_ABSPATH. Convert this to

a relpath and put that into the op_delete baton.

(scan_deletion_txn): Update a comment that referred to the BASE_NODE table.

This is now called NODES_BASE in the query this code is evaluating.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_op_delete): Add MOVED_TO_ABSPATH parameter and update docstring.

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

subversion/libsvn_wc/update_editor.c

(do_delete, add_directory): Adjust calls to svn_wc__db_op_delete().

  1. … 7 more files in changeset.
Fix issue 3972, revert always claims to revert symlinks

* subversion/libsvn_wc/adm_ops.c

(revert_restore): Move executable/read-only queries closer to the point

where the values are used, don't do executable processing for symlinks.

* subversion/tests/cmdline/special_tests.py

(symlink_destination_change): Extend to include a repeat revert.

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

(revert_restore): Further extend the conditional variable declaration and

usage to another variable.

* subversion/libsvn_wc/adm_ops.c

(revert_restore): Conditionally declare and assign a variable which is only

used conditionally.

Collapse the scope on several variables in our codebase.

Found by: Philipp Kloke <philipp.kloke@web.de>

* subversion/libsvn_fs_fs/tree.c

(history_prev),

* subversion/libsvn_subr/mergeinfo.c

(combine_with_lastrange),

* subversion/libsvn_subr/simple_providers.c

(svn_auth__simple_first_creds_helper),

* subversion/tests/libsvn_fs_base/fs-base-test.c

(create_within_copy),

* subversion/libsvn_wc/adm_ops.c

(check_can_add_node),

* subversion/libsvn_client/merge.c

(remove_noop_merge_ranges, do_directory_merge),

* subversion/libsvn_client/delete.c

(svn_client_delete4):

Tighten various variable scopes.

  1. … 6 more files in changeset.
Followup to r1140505. Fix indentation.

* [everywhere]: Fix indentation fallout from the

svn_error_return() -> svn_error_trace() rename.

Patch by: Noorul Islam K M <noorul{_AT_}collab.net>

  1. … 37 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.
As a follow-up to r1138871, rename status_unauthz again (formerly

status_absent), this time to status_server_excluded.

See for related discussion this post and follow-ups:

From: C. Michael Pilato

To: dev@

Subject: Re: svn commit: r1138871 - in /subversion/trunk/subversion:

include/private/ libsvn_client/ libsvn_wc/ tests/libsvn_wc/

Message-ID: <4E0346D4.4040400@collab.net>

http://svn.haxx.se/dev/archive-2011-06/0727.shtml

Suggested by: julianfoad

(the new name 'server-excluded')

* subversion/include/private/svn_wc_private.h

(svn_wc__node_is_status_unauthz): Rename to...

(svn_wc__node_is_status_server_excluded): ... this, and rename the

'is_unauthz' output parameter to 'is_server_excluded'.

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

subversion/libsvn_wc/props.c,

subversion/libsvn_wc/adm_ops.c,

subversion/libsvn_wc/adm_crawler.c,

subversion/libsvn_wc/conflicts.c,

subversion/libsvn_wc/crop.c,

subversion/libsvn_wc/diff_editor.c

subversion/libsvn_wc/adm_files.c,

subversion/libsvn_wc/update_editor.c,

subversion/libsvn_wc/info.c,

subversion/libsvn_wc/copy.c,

subversion/libsvn_wc/ambient_depth_filter_editor.c,

subversion/libsvn_wc/status.c,

subversion/libsvn_wc/lock.c,

subversion/libsvn_wc/entries.c,

subversion/libsvn_wc/wc_db.c,

subversion/libsvn_wc/wc_db.h,

subversion/libsvn_wc/node.c,

subversion/libsvn_wc/cleanup.c,

subversion/libsvn_wc/workqueue.c,

subversion/libsvn_client/copy.c,

(test_getting_info, validate_node, test_inserting_nodes, test_pdh,

svn_wc__perform_props_merge, svn_wc__get_pristine_props, svn_wc_delete4,

check_can_add_to_parent, revert_restore, report_revisions_and_depths,

recursive_resolve_conflict, crop_children, svn_wc_exclude, svn_wc_crop_tree2,

walk_local_nodes_diff, report_wc_directory_as_added,

svn_wc__text_base_path_to_read, svn_wc__get_pristine_contents,

IS_NODE_PRESENT, check_tree_conflict, delete_entry, absent_node,

svn_wc__check_wc_root, build_info_for_entry, copy_versioned_dir,

svn_wc_copy3, make_file_baton, open_root, delete_entry, open_directory,

get_dir_status, internal_status, svn_wc__internal_check_wc, adm_available,

read_one_entry, write_entry, kind_map, insert_base_node,

add_absent_excluded_not_present_node, svn_wc__db_base_add_absent_node,

db_op_copy, db_op_copy_shadowed_layer, check_replace_txn,

bump_node_revision, bump_revisions_post_update, svn_wc__db_node_hidden,

svn_wc__db_status_t, svn_wc__db_base_add_symlink,

svn_wc__db_op_set_tree_conflict, convert_db_kind_to_node_kind,

walker_helper, svn_wc__internal_walk_children,

svn_wc__node_is_status_absent, svn_wc__internal_node_get_schedule,

svn_wc__check_for_obstructions, repair_timestamps, remove_base_node,

repos_to_wc_copy_locked): Rename things as follows:

status_unauthz -> status_server_excluded; is_unauthz -> is_server_excluded

  1. … 21 more files in changeset.
As part of internal API cleanup, and in the name of code clarity,

rename svn_wc__db_status_absent to svn_wc__db_status_unauthz (not

authorized), because this is what 'absent' really means. Now there

is less potential for confusing 'absent' with 'not-present' and 'excluded'.

Discussed on IRC with Julian and Bert (not on dev@, but I still wanted

to mention that this wasn't just my own idea).

We considered postponing this step to post-1.7 but Bert pointed out

that doing so would unnecessarily make backport merges harder.

But note that this does not rename all occurrences of the term 'absent'

so we'll have to live with historical baggage in some function names,

comments, etc.

Neither does this change the wc.db schema. But I think it would be good

to rename the NODES presence value "absent" to "unauthz" as well in a

separate step (including a format bump).

Suggested by: julianfoad

(the new name 'unauthz')

* subversion/include/private/svn_wc_private.h

(svn_wc__node_is_status_absent): Rename to...

(svn_wc__node_is_status_unauthz): ... this, and rename the 'is_absent'

output parameter to 'is_unauthz'.

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

subversion/libsvn_wc/props.c,

subversion/libsvn_wc/adm_ops.c,

subversion/libsvn_wc/adm_crawler.c,

subversion/libsvn_wc/conflicts.c,

subversion/libsvn_wc/crop.c,

subversion/libsvn_wc/diff_editor.c

subversion/libsvn_wc/adm_files.c,

subversion/libsvn_wc/update_editor.c,

subversion/libsvn_wc/info.c,

subversion/libsvn_wc/copy.c,

subversion/libsvn_wc/ambient_depth_filter_editor.c,

subversion/libsvn_wc/status.c,

subversion/libsvn_wc/lock.c,

subversion/libsvn_wc/entries.c,

subversion/libsvn_wc/wc_db.c,

subversion/libsvn_wc/wc_db.h,

subversion/libsvn_wc/node.c,

subversion/libsvn_wc/cleanup.c,

subversion/libsvn_wc/workqueue.c,

subversion/libsvn_client/copy.c,

(test_getting_info, validate_node, test_inserting_nodes, test_pdh,

svn_wc__perform_props_merge, svn_wc__get_pristine_props, svn_wc_delete4,

check_can_add_to_parent, revert_restore, report_revisions_and_depths,

recursive_resolve_conflict, crop_children, svn_wc_exclude, svn_wc_crop_tree2,

walk_local_nodes_diff, report_wc_directory_as_added,

svn_wc__text_base_path_to_read, svn_wc__get_pristine_contents,

IS_NODE_PRESENT, check_tree_conflict, delete_entry, absent_node,

svn_wc__check_wc_root, build_info_for_entry, copy_versioned_dir,

svn_wc_copy3, make_file_baton, open_root, delete_entry, open_directory,

get_dir_status, internal_status, svn_wc__internal_check_wc, adm_available,

read_one_entry, write_entry, kind_map, insert_base_node,

add_absent_excluded_not_present_node, svn_wc__db_base_add_absent_node,

db_op_copy, db_op_copy_shadowed_layer, check_replace_txn,

bump_node_revision, bump_revisions_post_update, svn_wc__db_node_hidden,

svn_wc__db_status_t, svn_wc__db_base_add_symlink,

svn_wc__db_op_set_tree_conflict, convert_db_kind_to_node_kind,

walker_helper, svn_wc__internal_walk_children,

svn_wc__node_is_status_absent, svn_wc__internal_node_get_schedule,

svn_wc__check_for_obstructions, repair_timestamps, remove_base_node,

repos_to_wc_copy_locked): Rename things as follows:

status_absent -> status_unauthz; is_absent -> is_unauthz

  1. … 21 more files in changeset.
The semi-annual trailing whitespace cleansing ritual.

* everywhere:

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

sed -i -e 's/[ \t]*$//' `find . -name "*.$extsn" | xargs grep '[ \t]$' -l`

done

  1. … 144 more files in changeset.
Make these new APIs private: svn_uri_is_ancestor(), svn_relpath_is_ancestor().

* subversion/include/svn_dirent_uri.h,

subversion/libsvn_subr/dirent_uri.c

(svn_uri_is_ancestor): Rename to svn_uri__is_ancestor().

(svn_relpath_is_ancestor): Rename to svn_relpath__is_ancestor().

* Everywhere else: Adjust calls.

  1. … 20 more files in changeset.
Make svn_uri_skip_ancestor() URI-decode its result, because that makes sense

for returning a relpath, and because that's what all current callers want,

and because that brings the semantics of this function and svn_uri_is_child()

one step closer together.

* subversion/include/svn_dirent_uri.h,

subversion/libsvn_subr/dirent_uri.c

(svn_uri_skip_ancestor): Decode the result. Add a result pool parameter.

* subversion/libsvn_client/commit.c

(collect_lock_tokens): Don't decode the result after calling it.

* subversion/libsvn_client/commit_util.c

(harvest_copy_committables): Same.

* subversion/libsvn_client/merge.c

(merge_reintegrate_locked): Same.

* subversion/libsvn_client/util.c

(svn_client__path_relative_to_root): Same.

* subversion/libsvn_ra_local/ra_plugin.c

(reporter_link_path): Same.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_add4): Same.

* subversion/libsvn_wc/update_editor.c

(make_editor, svn_wc_add_repos_file4): Same.

* subversion/tests/libsvn_subr/dirent_uri-test.c

(test_uri_skip_ancestor): Adjust the call.

  1. … 9 more files in changeset.
Fix issue 3820, replacing a file with a directory clears any changelist.

* subversion/libsvn_wc/wc_db.c

(insert_working_node): Remove any changelist for directories.

* subversion/libsvn_wc/adm_ops.c

(add_from_disk): Don't remove changelist.

* subversion/libsvn_wc/wc-queries.sql

(STMT_UPDATE_ACTUAL_CLEAR_CHANGELIST): New.

* subversion/tests/cmdline/changelist_tests.py

(change_to_dir): Remove XFAIL, restore changelist before testing

that merge removes it.

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

(svn_wc_delete4): Following up on r1132948 and r1132919, answer my own

question: We can't just remove conflict markers in a keep_local scenario,

as that would remove conflict markers from the wrong directory, in case

we are just changing the casing of a node on a case insensitive filesystem.

Reapply a heavily tweaked version of sbutler's patch that made svn_wc_delete4

clean up conflict marker files of deleted nodes.

Compared to the original patch in r1132834: Don't use a helper function that

reimplements passing TRUE for svn_io_remove_file2's ignore_enoent. Avoid

error leaks. Perform the in-db deletion before removing the marker files.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_delete4): Check for conflicts and remove conflict marker files. Rename

argument to scratch_pool.

Revert r1132834 because the Windows buildbots broke and the move-command

performance took a big hit.

Suggested by: rhuijben

  1. … 2 more files in changeset.
Fix the move command for issue 3899 (auto resolve for wc-wc copies/moves).

* subversion/tests/cmdline/copy_tests.py

(copying_conflicts): Rename to...

(copy_and_move_conflicts): ...this and add test cases for moves.

* subversion/libsvn_client/copy.c

(do_wc_to_wc_moves_with_locks2): Let svn_wc_copy3() copy the items and

let svn_wc_delete4() delete them. This reverts r1061328.

* subversion/libsvn_wc/adm_ops.c

(attempt_deletion): New function.

(svn_wc_delete4): If a file has unresolved text or property conflicts,

delete conflict marker files.

  1. … 2 more files in changeset.
Fix issue 3894, clean up revert list SQL table.

* subversion/libsvn_wc/adm_ops.c

(revert_restore): Remove comments.

(new_revert_internal): Call svn_wc__db_revert_list_done.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DROP_REVERT_LIST): New.

* subversion/libsvn_wc/wc_db.c

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_revert_list_done): New.

  1. … 3 more files in changeset.
Fix issue 3900, wc delete of presence=absent nodes

* subversion/libsvn_wc/wc_db.c

(op_delete_txn): Check for absent nodes.

* subversion/libsvn_wc/adm_ops.c

(svn_wc_delete4): No need to check for absent node.

* subversion/tests/cmdline/authz_tests.py

(wc_delete): New test.

(test_list): Add new test.

  1. … 2 more files in changeset.
As part of issue #3779, "actual-only nodes need regression tests",

make 'svn add' detect tree conflict victims that do not exist on disk

and prevent adding new nodes at that path with a meaningful error message.

This implies that if users need to add a new node to resolve the conflict

they need to mark the conflict as resolved first. I think this is safer

than allowing accidental additions to take place. Since the node is not

visible on disk the addition might be a mistake.

* subversion/libsvn_wc/adm_ops.c

(check_can_add_node): Don't allow adding new items on top of nonexistent

conflicted nodes.

* subversion/libsvn_client/add.c

(add): As previous.

* subversion/tests/cmdline/tree_conflict_tests.py

(actual_only_node_behaviour): Adjust test cases for 'add' and 'mkdir'.

  1. … 2 more files in changeset.
With the simplification of new_revert_partial() in r1104185, the

REVERT_ROOT parameter is not used. In fact, it is not used by this entire

set of revert functions. So... nuke it. From orbit. It's the only way to

be safe.

Also, fold revert_internal() into svn_wc_revert4().

* subversion/libsvn_wc/adm_ops.c:

(revert_restore): remove REVERT_ROOT and adjust recursive call.

(new_revert_internal): remove REVERT_ROOT and adjust call to

revert_restore().

(new_revert_changelist): remove REVERT_ROOT and adjust recursive call.

adjust call to new_revert_internal().

(new_revert_partial): remove REVERT_ROOT and adjust calls to

new_revert_internal().

(revert_internal): removed. folded into ...

(svn_wc_revert4): ... here. directly call new_revert_changelist() if we

have any changelist_filters. call new_revert_internal() or

new_revert_partial() depending upon the DEPTH parameter. add an error

return for bogus DEPTH values.

Unwind a useless recursion. The child nodes never recursed beyond the

simple call to new_revert_internal(), so that call just moves inside the

loop itself.

* subversion/libsvn_wc/adm_ops.c:

(new_revert_changelist): formatting change only

(new_revert_partial): don't always read the kind; it will be read later,

and only when necessary. the root of the revert will always be

reverted (via a call to new_revert_internal). within the child loop,

directly call new_revert_internal with a svn_depth_empty to ensure

just that node is reverted. the iterpool is created a little earlier

for some additional benefit.