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

Changeset 1467191 is being indexed.

* **/**

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.

If we just want to know whether a path is the working copy root ask

for that instead of asking for the path and performing a comparison.

* subversion/libsvn_wc/adm_files.c

(svn_wc__adm_destroy): Simplify code.

* subversion/libsvn_wc/adm_ops.c

(revert_internal): Simplify code.

* subversion/libsvn_wc/cleanup.c

(cleanup_internal): Simplify code.

* subversion/libsvn_wc/merge.c

(detranslate_wc_file): Don't fetch an unused variable.

  1. … 3 more files in changeset.
In the post commit handling, fetch a bit more information in a single

wc_db operation to avoid two further wc_db transactions.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): Add 3 arguments to avoid db_read_info() call.

(svn_wc__process_committed_internal): Read information before leaf call and

calculate kind after performing the leaf call.

Don't obtain kind and status for early filtering as a simple hash table

lookup and filtering in the next function avoids a db call.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): As commit handles committing to the BASE layer

it should just use the base remove function. In this case both remove

functions have the same effect as the function only opperates on deletes

that directly apply on BASE nodes.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): Remove two unused local variables.

Replace the very wc-1.0 style svn_wc__internal_remove_from_revision_control

function with an atomic wc-ng function. This makes operations like reducing the

depth of a working copy or removing externals from a wc atomic by performing

a db operation and installing workqueue items.

* subversion/libsvn_client/externals.c

(relegate_dir_external): Obtain lock here that was obtained in the caller.

Properly handle working copy renames.

(switch_dir_external): Remove function that has been moved to the callee.

* subversion/libsvn_wc/adm_ops.c

(process_committed_leaf): Update caller.

* subversion/libsvn_wc/crop.c

(includes): Include workqueue.h.

(IGNORE_LOCAL_MOD): Remove now unused macro.

(crop_children): Use db operation directly.

(svn_wc_exclude): Use db operation directly. Avoid second db operation

by passing absent information.

(svn_wc_crop_tree2): Update caller. Run workqueue.

* subversion/libsvn_wc/externals.c

(svn_wc__external_remove): If we leave an external, leave the whole external

by using the fail early mode.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_WORKING_PRESENT,

STMT_DELETE_NODE_RECURSIVE,

STMT_DELETE_NODE): New queries.

* subversion/libsvn_wc/wc_db.c

(remove_node_baton): Add fields for new options.

(remove_node_txn): Add code to create workqueue items for nodes that exist

on disk. Provide cancellation checking when checking for changes.

Allow setting excluded and not-present.

(svn_wc__db_op_remove_node): Update caller.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_op_remove_node): Update prototype and documentation.

  1. … 6 more files in changeset.
Handle an currently always FALSE argument of svn_wc_remove_from_revision_control2

in the public wrapper to make it easier to switch the implementation to an

atomic operation.

* subversion/libsvn_wc/adm_ops.c

(svn_wc__internal_remove_from_revision_control): Remove instant_error argument,

assume its value is false trough this function.

(remove_from_revision_status_callback): New function, implementing

instant_error as status walker callback.

(svn_wc_remove_from_revision_control2): Walk status before calling

svn_wc__internal_remove_from_revision_control when instant_error is true.

* subversion/libsvn_wc/crop.c

(crop_children): Update caller.

* subversion/libsvn_wc/wc.h

(svn_wc__internal_remove_from_revision_control): Remove argument.

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

(revert_partial): Verify type of the child for depth processing (instead

of type of the parent *directory*). This fixes the problem checked for

since r1365549.

Make 'svn rm' remove externals registrations below its targets.

We allow deleting parents of file externals (as we allow deleting

directories that contain switched paths) and directories that have

directory externals somewhere below them.

This patch removes the registration in the EXTERNALS table and for

file externals the entire file external so the next update will find

a normal working copy.

The new behavior is more what users expect, reduces the number of strange

database states and resolves some regressions since 1.6.

Suggested by: Dmitry Pavlenko <pavlenko{_AT_}tmatesoft.com>

* subversion/libsvn_wc/adm_ops.c

(svn_wc__delete_internal): Update caller.

* subversion/libsvn_wc/update_editor.c

(delete_entry): Update caller.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DELETE_FILE_EXTERNALS,

STMT_DELETE_FILE_EXTERNAL_REGISTATIONS,

STMT_DELETE_EXTERNAL_REGISTATIONS): New statements.

* subversion/libsvn_wc/wc_db.c

(op_delete_baton_t): Add delete_dir_externals.

(delete_node): Delete externals if necessary.

(op_delete_many_txn): Update caller.

(svn_wc__db_op_delete): Pass delete_dir_externals.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_op_delete): Add delete_dir_externals argument and update

documentation.

(svn_wc__db_op_delete_many): Update documentation.

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

(do_delete): Update caller.

(copy_file_externals): Update expected result.

  1. … 5 more files in changeset.