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

Changeset 1661672 is being indexed.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_BASE_PRESENT): Following up on r1661591, remove unused query.

Make svn update --set-depth <something-limiting> properly avoid removing

local changes, instead of leaving just some items as unversioned, following

the same handling as we do with updates.

It already handled some changes of the root properly, but in most cases

it could be as destructive as as 'svn revert -R TARGET'

In the background this makes the crop/exclude operation the BASE operation

that it should have been using from the start.

* subversion/libsvn_wc/crop.c

(crop_children): Only try to remove BASE nodes affected by the depth

filter. Don't remove nodes that are changed/shadowed.

* subversion/libsvn_wc/wc-queries.sql

(STMT_UPDATE_NODE_BASE_DEPTH): Only store depth when presence specifies

there is an actual directory (to make the wc-db function fail if it

isn't).

* subversion/tests/cmdline/depth_tests.py

(fold_tree_with_unversioned_modified_items): Update expected results.

  1. … 2 more files in changeset.
Avoid a db query per childnode when walking children during merge calculations

by performing the 'hidden' filtering inside sqlite on a common operation.

* subversion/include/private/svn_wc_private.h

(svn_wc__node_get_children_of_working_node): Remove show_hidden argument as

non of the callers really wanted all nodes, including hidden.

(svn_wc__node_get_not_present_children): New function, for commit processing.

* subversion/libsvn_client/commit_util.c

(harvest_not_present_for_copy): Fetch just the not-present children. commit_relpath

is always set in copy mode, so no need to check.

* subversion/libsvn_client/merge.c

(insert_parent_and_sibs_of_sw_absent_del_subtree,

get_mergeinfo_paths): Ignore base-children when shadowed (as expected during merge

and to gain a performance bump)

* subversion/libsvn_wc/node.c

(svn_wc__node_get_children_of_working_node): Remove argument. Update caller.

(svn_wc__node_get_not_present_children): New function.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_WORKING_CHILDREN): Select only existing children.

(STMT_SELECT_BASE_NOT_PRESENT_CHILDREN): New query.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_base_read_not_present_children): New function.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_base_read_not_present_children): New function.

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

(test_children_of_replaced_dir): Update test.

  1. … 7 more files in changeset.
Following up on r1661143, use even more free sqlite power:

ask sqlite to provide sorted and unique results for the children

queries that could provide multiple results.

Sqlite can do this for +- free, because all of that is stored

in the index it should use.

(The wc-queries test would provide an error if it used

intermediate storage for its calculations)

Verified with Sqlite 3.7, 3.8 (and by our wc-queries tests)

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_NODE_CHILDREN,

STMT_SELECT_WORKING_CHILDREN): Add DISTINCT and ORDER BY, to

guarantee stable results.

* subversion/libsvn_wc/wc_db.c

(gather_children): Remove now unneeded duplicate filtering.

  1. … 1 more file in changeset.
Make sure a depth limited commit that touches a move, but doesn't

commit it doesn't break move recording by moving some parts into

BASE (creating invalid state) and discarding other parts.

* subversion/libsvn_wc/wc-queries.sql

(STMT_COMMIT_DESCENDANTS_TO_BASE): Clear moved_to information.

* subversion/libsvn_wc/wc_db.c

(moved_descendant_collect): New function extracted from...

(moved_descendant_commit): ... this. Update recursive call.

(commit_node): Collect moves that are about to be removed,

and properly remove their recording if necessary.

Stop removing locks recursively, let libsvn_client handle

this properly.

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

(commit_moved_away_descendant): Extend test to verify for

bad recording that previously occurred.

  1. … 2 more files in changeset.
Bring the wc-db tests in the world where we store moves in WORKING, and

fix the db query that allowed this test to survive so long.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_DELETION_INFO): Rewrite as join to allow access to more

columns. Add moved_to result.

(STMT_SELECT_DELETION_INFO_SCAN): Remove known bad statement.

* subversion/libsvn_wc/wc_db.c

(scan_deletion_txn): Always use STMT_SELECT_DELETION_INFO.

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

(TESTING_DATA): Stop storing moves in the pre 1.8.x locations,

move them to WORKING instead.

  1. … 2 more files in changeset.
Fix svn_wc__db_op_make_copy_internal()'s handling of mixed revision BASE trees.

This fixes some issues around tree conflict handling, and improves

database consistency.

* build/transform_sql.py

(process_file): Allow passing columns and binding variables as argument of

IS_STRICT_DESCENDANT_OF, like the other macros.

* subversion/libsvn_wc/wc-checks.sql

(STMT_STATIC_VERIFY): Add documentation to the older statements. Extend.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DELETE_WORKING_BASE_DELETE): Split into non-recursive...

(STMT_DELETE_WORKING_BASE_DELETE_RECURSIVE): ... and recursive variants.

(STMT_INSERT_WORKING_NODE_FROM_BASE_COPY): Allow replacing nodes, and

handle moved_to when doing that.

* subversion/libsvn_wc/wc_db.c

(db_base_remove): Update caller.

(make_copy_txn): Add recursion arguments to determine when a new op-depth

is needed. Simplify code, by moving the initial shadowing to the calling

function.

(make_copy_move_moved_to): New function.

(svn_wc__db_op_make_copy_internal): Update caller. Shadow all nodes with

base-deleted before calling make_copy_txn. Move moved-to information

to this layer.

* subversion/tests/cmdline/tree_conflict_tests.py

(update_delete_mixed_rev): Remove XFail. Tweak status value.

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

(make_copy_mixed): New function. Tests svn_wc__db_op_make_copy_internal.

make_copy_and_delete_mixed): New functions. Tests svn_wc__db_base_remove

and shows an existing issue with move handling on base-delete.

(test_list): Add new items.

  1. … 5 more files in changeset.
Stop creating empty ACTUAL_NODE records for directories when using

'svn changelist --depth infinty new WC'

* subversion/libsvn_wc/wc-queries.sql

(STMT_INSERT_ACTUAL_EMPTIES_FILES): New query.

(STMT_DELETE_ACTUAL_EMPTIES): Also try delete node itself.

* subversion/libsvn_wc/wc_db.c

(set_changelist_txn): Use STMT_INSERT_ACTUAL_EMPTIES_FILES to

avoid creating unneeded records.

* subversion/svn/changelist-cmd.c

(svn_cl__changelist): Remove long outdated comment. This bad

pattern was fixed a long time ago.

* subversion/tests/libsvn_wc/wc-queries-test.c

(slow_statements): Add STMT_INSERT_ACTUAL_EMPTIES_FILES.

(parse_explanation_item): Handle new output style in recent Sqlite versions.

  1. … 3 more files in changeset.
On move-update layer copying remove ACTUAL nodes for nodes that no longer

exist and are not delete-delete conflicted.

While not really a bug, leaving dangling ACTUAL records creates nonstandard

database states and therefore may trigger untested code paths.

(You might see this as changelists or property changes on newly added

files/directories)

* subversion/libsvn_wc/wc-queries.sql

(STMT_CLEAR_ACTUAL_NODE_LEAVING_CONFLICT): New statement.

* subversion/libsvn_wc/wc_db.c

(clear_or_remove_actual): New function.

(svn_wc__db_op_copy_layer_internal): Call clear_or_remove_actual on

removed nodes. Remove TODO comment.

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

(move_update_delete_mods,

move4_update_delself_AAA): Extend expectations to make it easier

to spot problems.

  1. … 2 more files in changeset.
Following up on r1659509, extend the whitespace cleanup script to include

.sql and .sh files

* tools/dev/remove-trailing-whitespace.sh

Update script.

* autogen.sh

* subversion/libsvn_wc/wc-metadata.sql

* subversion/libsvn_wc/wc-queries.sql

* subversion/tests/cmdline/dav-mirror-autocheck.sh

* subversion/tests/cmdline/davautocheck.sh

* subversion/tests/cmdline/lock_tests.py

* tools/buildbot/slaves/i686-debian-sarge1/svnlog.sh

* tools/buildbot/slaves/svn-x64-centos/svnbuild.sh

* tools/buildbot/slaves/svn-x64-centos/svnlog.sh

* tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnlog.sh

* tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnlog.sh

* tools/buildbot/slaves/ubuntu-x64/svnlog.sh

* tools/client-side/svn-ssl-fingerprints.sh

* tools/dev/benchmarks/large_dirs/create_bigdir.sh

* tools/dist/dist.sh

* tools/dist/nightly.sh

* tools/hook-scripts/mailer/tests/mailer-init.sh

* tools/po/po-update.sh

Apply whitespace cleanup.

  1. … 18 more files in changeset.
* subversion/libsvn_wc/wc-queries.sql

(STMT_COPY_NODE_MOVE): Keep recorded size and timestamp unless checksum

changes. The file merge code (on prop and text changes) should handle

all cases, but comparing checksum (again) here is a cheap safety net.

Resolve an old TODO from one of the op-depth bump helper functions:

Cleanup some test code.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_LAYER_FOR_REPLACE): Remove unused inner query.

* subversion/libsvn_wc/wc_db.c

(db_extend_parent_delete): Remove unused diagnostics argument.

(insert_base_node): Update caller.

(svn_wc__db_op_copy_layer_internal): Use a simple check to see

when a parent delete might need extension.

  1. … 1 more file in changeset.
Make the (non recursive) revert db operation properly report tree conflicts

that it creates by both fixing what is stored in the tree conflict and by

properly creating notifications.

Note that a recursive revert wouldn't encounter this problem as it

would just break the moves.

* subversion/libsvn_wc/token-map.h

(kind_map): New array.

* subversion/libsvn_wc/wc-queries.sql

(STMT_CREATE_REVERT_LIST): Only add interesting rows.

(STMT_SELECT_REVERT_LIST_RECURSIVE): Make the revert information available

instead of just the name.

(STMT_CREATE_UPDATE_MOVE_LIST): Store kind as token like in other places,

to allow transforming to revert information.

(STMT_MOVE_NOTIFY_TO_REVERT): New statement.

* subversion/libsvn_wc/wc_db.c

(op_revert_txn): Only bump moved nodes after they have been moved to the

final op-depth. Transform move_update information into revert information.

(revert_list_read): Simplify, since we can now assume only normal reverts

are in the list.

(svn_wc__db_revert_list_notify): Handle new tree conflict notifications and

pass kind when available.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_op_raise_moved_away_internal): New function.

* subversion/libsvn_wc/wc_db_update_move.c

(update_move_list_add): Set kind as token instead of as integer.

(svn_wc__db_update_move_list_notify): Read kind as token.

(resolve_delete_raise_moved_away): Rename to...

(svn_wc__db_op_raise_moved_away_internal): ... this. Make public and add

delete_op_depth argument, to allow bumping from a higher root node.

(break_moved_away_children): Use existing kind column to improve

notifications.

* subversion/tests/cmdline/move_tests.py

(revert_del_root_of_move): New function.

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

(move_in_delete): Remove ### comment.

(test_funcs): Remove XFail marker from move_in_delete.

  1. … 6 more files in changeset.
Improve depth correctness during tree conflict resolving a bit more by

requiring that the proper op-depth of the nodes is passed around instead

of some 'good enough depth'. This made some buggy corner cases around not-

present nodes visible, which are now also fixed.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_DEPTH_NODE): Add moved fields. Remove nonsensical field.

(STMT_SELECT_OP_DEPTH_CHILDREN): Request strict ordering via existing index.

(STMT_SELECT_OP_DEPTH_CHILDREN_EXISTS): New query with presence filter.

(STMT_SELECT_OP_DEPTH_MOVED_TO): Require that the node actually exists

or it wouldn't be a move.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_get_children_op_depth): Remove function.

(svn_wc__db_depth_get_info): Update column index.

(svn_wc__db_op_depth_moved_to): Redefine function as...

(svn_wc__db_scan_moved_to_internal): ... this, with stricter op-depth

definition.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_base_moved_to): Tweak documentation.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_get_children_op_depth): Remove function.

(svn_wc__db_op_depth_moved_to): Rename to...

(svn_wc__db_scan_moved_to_internal): ... this and update docs.

* subversion/libsvn_wc/wc_db_update_move.c

(find_src_op_depth): New function.

(mark_tc_on_op_root): If there is no old kind, there can't be

a replacement.

(tc_editor_delete): Pass new kind to improve tree conflict.

(get_info): Directly use db query to get items pre-sorted without

copying twice, and to avoid not-present node bugs.

(drive_tree_conflict_editor): Remove unused arguments. Move check

to caller.

(update_moved_away_conflict_victim): Use scan_moved_to after obtaining

the source op-depth. Move assertion here. Update caller.

(svn_wc__db_bump_moved_away): Update caller.

(break_moved_away): Obtain proper depth instead of passing some

good enough depth.

  1. … 4 more files in changeset.
Fix yet another case where we corrupted the move tracking information during

conflict resolving. When breaking a move it was possible that moved_here

was reset, but moved_to kept.

As part of this fix I made two database statements more similar.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_OP_DEPTH_MOVED_PAIR): Rename to...

(STMT_SELECT_MOVED_DESCENDANTS_SHD): and rename some aliases.

(STMT_SELECT_MOVED_DESCENDANTS): Rename to...

(STMT_SELECT_MOVED_DESCENDANTS_SRC): and update query layout and result

columns.

* subversion/libsvn_wc/wc_db.c

(op_revert_txn): Update caller to avoid db query that might fail to

obtain information we already have.

(moved_descendant_commit): Update statement usage.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_resolve_break_moved_away_internal): Remove function.

(svn_wc__db_op_break_move_internal): New function.

* subversion/libsvn_wc/wc_db_update_move.c

(resolve_delete_raise_moved_away): Update query usage.

(break_move): Rename to...

(svn_wc__db_op_break_move_internal): ... this and verify if the move

source actually exists (which in some cases it didn't)

(svn_wc__db_resolve_break_moved_away_internal): Rename to...

(break_moved_away): ... this. Update caller.

(break_moved_away_children_internal): Rename to...

(break_moved_away_children): ... this. Update statement usage.

The original code read a non existing op-depth column and as

such always got op-depth 0.

(svn_wc__db_resolve_break_moved_away,

svn_wc__db_resolve_break_moved_away_children): Update caller.

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

(del4_update_edit_AAA): Extend test. The original version had an

assumption on the bug, but masked the real problem because it

only tested the move source.

  1. … 4 more files in changeset.
Instead of transforming nodes into an copy by changing their op-depth make

a proper copy, to allow the layer bump code to handle further edge cases

like things that are recorded while shadowing.

* subversion/libsvn_wc/wc-queries.sql

(STMT_UPDATE_OP_DEPTH_RECURSIVE): Remove query.

(STMT_COPY_OP_DEPTH_RECURSIVE): New query.

* subversion/libsvn_wc/wc_db.c

(make_copy_txn): Remove two unused arguments and their handling.

Move the flush, conflict and work item code to caller.

(svn_wc__db_op_make_copy_internal): New function, containing some

bits from make_copy_txn() and some from svn_wc__db_op_make_copy(),

running inside a transaction. Allow handling the other valid make-copy

case.

(svn_wc__db_op_make_copy): Call svn_wc__db_op_make_copy_internal to

do several queries inside a transaction.

* subversion/libsvn_wc/wc_db.h

(svn_wc__db_op_make_copy): Extend documentation.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_op_make_copy_internal): New function.

* subversion/libsvn_wc/wc_db_update_move.c

(tc_editor_delete): Use svn_wc__db_op_make_copy_internal() to make

the copy.

  1. … 4 more files in changeset.
* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_OP_DEPTH_MOVED_PAIR): The op-depth we want to use is the

same for all records, so only query it once.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_OP_DEPTH_MOVED_PAIR): Use a normal join to make it easier

to compare this statement with others.

Remove more duplicated DB operations in the move-update logic.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DELETE_WORKING_OP_DEPTH_ABOVE): Remove unused statement.

* subversion/libsvn_wc/wc_db_update_move.c

(tc_editor_delete): No need to remove nodes here, when the layer copying

handles this later. Avoids bad intermediate DB states and losing move info.

  1. … 1 more file in changeset.
Turn the replace_moved_layer() function in the move-update logic into an

internal wc_db function. This allows hiding a few more functions that are

too easy to abuse. And this function might be useful outside the move logic.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_DESCENDANTS_OP_DEPTH_RV): Handle incomplete presence.

(STMT_SELECT_NO_LONGER_MOVED_RV): Obtain shadowing information.

(STMT_DELETE_NO_LOWER_LAYER): Remove unused statement.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_extend_parent_delete): Make static and rename to...

(db_extend_parent_delete): ... this.

(svn_wc__db_retract_parent_delete): Make static and rename to...

(db_retract_parent_delete): ... this.

(insert_base_node,

db_base_remove): Update caller.

(svn_wc__db_op_copy_layer_internal): New function.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_extend_parent_delete,

svn_wc__db_retract_parent_delete): Remove functions.

(svn_wc__db_op_copy_layer_internal): New function.

* subversion/libsvn_wc/wc_db_update_move.c

(delete_move_leaf): Remove function. Folded queries to fold this

function into its only caller.

(replace_moved_layer): Moved to wc_db.c as svn_wc__db_op_copy_layer_internal.

(drive_tree_conflict_editor): Update caller. Verify lock.

(bump_moved_layer): Update caller. Verify lock on origin.

  1. … 3 more files in changeset.
Stop doing some work twice in the move-update logic, now that we can rely

on the layer duplicate code to the right thing.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DELETE_NO_LOWER_LAYER,

STMT_REPLACE_WITH_BASE_DELETED): Remove recursion over descendants.

* subversion/libsvn_wc/wc_db_update_move.c

(delete_move_leaf): Stop handling descendants too, as our only caller

does that for us.

* subversion/libsvn_wc/wc_db_update_move.c

(delete_move_leaf): This function is called per node, so no need to recurse.

(update_moved_away_node): Remove unneeded call.

Handled from the layer update.

  1. … 1 more file in changeset.
Make the move-update-bump code properly recursive.

Some of the functions documented that they implemented recursive behavior,

but didn't really work this way as you can't use an Sqlite statement in

multiple places at once. Once the function returns the statement is used

as it was left in the inner function.

This allows integrating the two separate parts of the layer copy code.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_NO_LONGER_MOVED_RV): New statement.

(STMT_SELECT_MOVED_PAIR3): Update query to only find moves at the intended

op-depth.

* subversion/libsvn_wc/wc_db_update_move.c

(update_moved_away_node): Remove call to delete_move_leaf, that was already

documented to be placed wrong.

(replace_moved_layer): Use standard argument ordering. Implement the delete

part of the layer copying.

(drive_tree_conflict_editor): Update caller.

(bump_moved_layer): Cleanup argument usages. Pass calculated path.

(bump_pair_t): New struct.

(bump_moved_away): Cache query results to allow recursing. Otherwise the

statement is done once the inner function returns. Remove source hash,

as we can no longer get in an endless loop because we use strict op-depth.

(svn_wc__db_bump_moved_away): Update caller.

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

(nested_move_update): Extend test.

(move4_update_delself_AAA): Update expected results. Extend test.

  1. … 2 more files in changeset.
Make the move-update bumping code properly ignore not-present nodes

on the move target. These nodes can exist when moving a node with

not-present nodes (like after a commit, svn up -r 0), or when a mixed

revision tree would be recorded as move.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_LAYER_FOR_REPLACE): Extend query to obtain info about current

data at destination.

(STMT_SELECT_CHILDREN_OP_DEPTH): Rename to...

(STMT_SELECT_DESCENDANTS_OP_DEPTH_RV): ... this to document that it selects

more than immediate children. Ignore not-present nodes.

* subversion/libsvn_wc/wc_db.c

(svn_wc__db_extend_parent_delete): Add optional output argument.

(insert_base_node): Update caller.

* subversion/libsvn_wc/wc_db_private.h

(svn_wc__db_extend_parent_delete): Add optional output argument.

* subversion/libsvn_wc/wc_db_update_move.c

(tc_editor_delete): Update query user.

(update_moved_away_node): Update caller.

(replace_moved_layer): Use improved query. Add some still commented logic

detecting cases where a new node is added unshadowed, which in some

cases need special handling.

  1. … 3 more files in changeset.
Make some op-depth diagnostics code in wc_db capable of handling moves

that don't copy the exact whole layer. (Which is possible during conflict

handling and when the root of a mixed revision move is represented as move)

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_OP_DEPTH_MOVED_TO): Simplify query to avoid the case where

values might be NULL.

* subversion/libsvn_wc/wc_db.c

(follow_moved_to): Update query usage. Add some comments.

  1. … 1 more file in changeset.
Properly remove the working copy delete information for descendants of nodes that

are removed by the 'update move' handling. This resolves a case of an invalid

database state identified by the move4_update_delself_AAA() op-depth test.

* subversion/libsvn_wc/wc-queries.sql

(STMT_DELETE_WORKING_BASE_DELETE): Make the '0' for BASE nodes configurable

to allow using this same query for higher layers.

* subversion/libsvn_wc/wc_db.c

(db_base_remove): Update statement usage.

* subversion/libsvn_wc/wc_db_update_move.c

(delete_move_leaf): Replace baton with separate arguments. Retract

base-deletes recursively, instead of only for the node itself.

(update_moved_away_node): Update caller.

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

(move4_update_delself_AAA): Update assumptions, after fixing the root cause.

(test_funcs): Mark move4_update_delself_AAA PASS.

  1. … 3 more files in changeset.
Reintegrated the remote-only-status branch.
  1. … 25 more files in changeset.
In the delete node processing: obtain the node data directly via a query

instead of a read info and upto three more functions. Retrieving the

op-depth of the interesting layers earlier avoids a lot of unneeded

guessing, which appear to cause some bugs that I intend to fix in followup

patches.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_MOVED_FOR_DELETE): Replace subquery with value.

* subversion/libsvn_wc/wc_db.c

(delete_node): Obtain op_depth of what to delete and what to keep to avoid

having to query for these values many times.

  1. … 1 more file in changeset.
* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_MOVED_PAIR3): Following up on r1567109, define the complete

ordering instead of only that of paths.

Resolve an unneeded dependency on undocumented and version specific Sqlite

behavior. Without this patch some moved nodes might not be bumped during

update.

This resolves two failures in the test suite when running the tests with

the SVN_SQLITE_REVERSE_UNORDERED_SELECTS compile time option. Without this

patch these same errors can also occur when Sqlite chooses an unexpected

query plan.

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_MOVED_PAIR3): Use a UNION ALL and order by to make the query

report the matched rows in the ordering we expect in the C code.

(read: ancestor first)

* subversion/libsvn_wc/wc-queries.sql

(STMT_SELECT_LOCAL_RELPATH_OP_DEPTH): Tweak query to always return results

in an explicit order, as the usage of this query requires ancestors to be

inserted before their children.