summaryrefslogtreecommitdiff
path: root/subversion/libsvn_wc
diff options
context:
space:
mode:
Diffstat (limited to 'subversion/libsvn_wc')
-rw-r--r--subversion/libsvn_wc/README15
-rw-r--r--subversion/libsvn_wc/conflicts.c95
-rw-r--r--subversion/libsvn_wc/conflicts.h7
-rw-r--r--subversion/libsvn_wc/deprecated.c30
-rw-r--r--subversion/libsvn_wc/diff_local.c29
-rw-r--r--subversion/libsvn_wc/entries.c4
-rw-r--r--subversion/libsvn_wc/libsvn_wc.pc.in8
-rw-r--r--subversion/libsvn_wc/node.c28
-rw-r--r--subversion/libsvn_wc/props.c4
-rw-r--r--subversion/libsvn_wc/questions.c2
-rw-r--r--subversion/libsvn_wc/revert.c54
-rw-r--r--subversion/libsvn_wc/tree_conflicts.c2
-rw-r--r--subversion/libsvn_wc/update_editor.c33
-rw-r--r--subversion/libsvn_wc/upgrade.c4
-rw-r--r--subversion/libsvn_wc/wc-checks.h2
-rw-r--r--subversion/libsvn_wc/wc-metadata.h2
-rw-r--r--subversion/libsvn_wc/wc-queries.h1268
-rw-r--r--subversion/libsvn_wc/wc-queries.sql24
-rw-r--r--subversion/libsvn_wc/wc.h1
-rw-r--r--subversion/libsvn_wc/wc_db.c119
-rw-r--r--subversion/libsvn_wc/wc_db.h48
-rw-r--r--subversion/libsvn_wc/wc_db_update_move.c27
-rw-r--r--subversion/libsvn_wc/wc_db_wcroot.c16
-rw-r--r--subversion/libsvn_wc/wcroot_anchor.c16
24 files changed, 1096 insertions, 742 deletions
diff --git a/subversion/libsvn_wc/README b/subversion/libsvn_wc/README
index b5fc5293cd96..7475ec5331f3 100644
--- a/subversion/libsvn_wc/README
+++ b/subversion/libsvn_wc/README
@@ -94,6 +94,10 @@ copies.
.svn/wc.db /* SQLite database containing node metadata. */
pristine/ /* Sharded directory containing base files. */
tmp/ /* Local tmp area. */
+ experimental/ /* Data for experimental features. */
+ shelves/ /* Used by 1.10.x shelves implementation */
+ entries /* Stub file. */
+ format /* Stub file. */
`wc.db':
A self-contained SQLite database containing all the metadata Subversion
@@ -109,6 +113,17 @@ copies.
Pristines are used for sending diffs back to the server, etc.
+`experimental':
+ Experimental (unstable) features store their data here.
+
+`shelves':
+ Subversion 1.10's "svn shelve" command stores shelved changes here.
+ This directory is not used by any other minor release line.
+
+`entries', `format':
+ These stub files exist only to enable a pre-1.7 client to yield a clearer
+ error message.
+
How the client applies an update delta
--------------------------------------
diff --git a/subversion/libsvn_wc/conflicts.c b/subversion/libsvn_wc/conflicts.c
index 606710c69f00..b4bc6c05ad6c 100644
--- a/subversion/libsvn_wc/conflicts.c
+++ b/subversion/libsvn_wc/conflicts.c
@@ -539,6 +539,7 @@ svn_wc__conflict_skel_add_tree_conflict(svn_skel_t *conflict_skel,
svn_wc_conflict_reason_t reason,
svn_wc_conflict_action_t action,
const char *move_src_op_root_abspath,
+ const char *move_dst_op_root_abspath,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
@@ -555,18 +556,33 @@ svn_wc__conflict_skel_add_tree_conflict(svn_skel_t *conflict_skel,
tree_conflict = svn_skel__make_empty_list(result_pool);
- if (reason == svn_wc_conflict_reason_moved_away
- && move_src_op_root_abspath)
+ if (reason == svn_wc_conflict_reason_moved_away)
{
- const char *move_src_op_root_relpath;
+ if (move_dst_op_root_abspath)
+ {
+ const char *move_dst_op_root_relpath;
- SVN_ERR(svn_wc__db_to_relpath(&move_src_op_root_relpath,
- db, wri_abspath,
- move_src_op_root_abspath,
- result_pool, scratch_pool));
+ SVN_ERR(svn_wc__db_to_relpath(&move_dst_op_root_relpath,
+ db, wri_abspath,
+ move_dst_op_root_abspath,
+ result_pool, scratch_pool));
- svn_skel__prepend_str(move_src_op_root_relpath, tree_conflict,
- result_pool);
+ svn_skel__prepend_str(move_dst_op_root_relpath, tree_conflict,
+ result_pool);
+ }
+
+ if (move_src_op_root_abspath)
+ {
+ const char *move_src_op_root_relpath;
+
+ SVN_ERR(svn_wc__db_to_relpath(&move_src_op_root_relpath,
+ db, wri_abspath,
+ move_src_op_root_abspath,
+ result_pool, scratch_pool));
+
+ svn_skel__prepend_str(move_src_op_root_relpath, tree_conflict,
+ result_pool);
+ }
}
svn_skel__prepend_str(svn_token__to_word(action_map, action),
@@ -932,6 +948,7 @@ svn_error_t *
svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *reason,
svn_wc_conflict_action_t *action,
const char **move_src_op_root_abspath,
+ const char **move_dst_op_root_abspath,
svn_wc__db_t *db,
const char *wri_abspath,
const svn_skel_t *conflict_skel,
@@ -981,10 +998,10 @@ svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *reason,
c = c->next;
- if (move_src_op_root_abspath)
+ if (move_src_op_root_abspath || move_dst_op_root_abspath)
{
/* Only set for update and switch tree conflicts */
- if (c && is_moved_away)
+ if (c && is_moved_away && move_src_op_root_abspath)
{
const char *move_src_op_root_relpath
= apr_pstrmemdup(scratch_pool, c->data, c->len);
@@ -994,8 +1011,25 @@ svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *reason,
move_src_op_root_relpath,
result_pool, scratch_pool));
}
- else
+ else if (move_src_op_root_abspath)
*move_src_op_root_abspath = NULL;
+
+ if (c)
+ c = c->next;
+
+ if (c && is_moved_away && move_dst_op_root_abspath)
+ {
+ const char *move_dst_op_root_relpath
+ = apr_pstrmemdup(scratch_pool, c->data, c->len);
+
+ SVN_ERR(svn_wc__db_from_relpath(move_dst_op_root_abspath,
+ db, wri_abspath,
+ move_dst_op_root_relpath,
+ result_pool, scratch_pool));
+ }
+ else if (move_dst_op_root_abspath)
+ *move_dst_op_root_abspath = NULL;
+
}
return SVN_NO_ERROR;
@@ -1352,7 +1386,7 @@ generate_propconflict(svn_boolean_t *conflict_remains,
}
case svn_wc_conflict_choose_merged:
{
- if (!cdesc->merged_file
+ if (!cdesc->merged_file
&& (!result->merged_file && !result->merged_value))
return svn_error_create
(SVN_ERR_WC_CONFLICT_RESOLVER_FAILURE,
@@ -1801,7 +1835,7 @@ read_tree_conflict_desc(svn_wc_conflict_description2_t **desc,
svn_wc_conflict_action_t action;
SVN_ERR(svn_wc__conflict_read_tree_conflict(
- &reason, &action, NULL,
+ &reason, &action, NULL, NULL,
db, local_abspath, conflict_skel, scratch_pool, scratch_pool));
if (reason == svn_wc_conflict_reason_missing)
@@ -2347,7 +2381,7 @@ svn_wc__read_conflict_descriptions2_t(const apr_array_header_t **conflicts,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
- return svn_wc__read_conflicts(conflicts, NULL, wc_ctx->db, local_abspath,
+ return svn_wc__read_conflicts(conflicts, NULL, wc_ctx->db, local_abspath,
FALSE, FALSE, result_pool, scratch_pool);
}
@@ -2603,7 +2637,7 @@ resolve_prop_conflict_on_node(svn_boolean_t *did_resolve,
return SVN_NO_ERROR;
}
-/*
+/*
* Record a tree conflict resolution failure due to error condition ERR
* in the RESOLVE_LATER hash table. If the hash table is not available
* (meaning the caller does not wish to retry resolution later), or if
@@ -2676,7 +2710,7 @@ resolve_tree_conflict_on_node(svn_boolean_t *did_resolve,
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
&src_op_root_abspath,
- db, local_abspath,
+ NULL, db, local_abspath,
conflicts,
scratch_pool, scratch_pool));
@@ -2748,6 +2782,7 @@ resolve_tree_conflict_on_node(svn_boolean_t *did_resolve,
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
&src_op_root_abspath,
+ NULL,
db, local_abspath,
new_conflicts,
scratch_pool,
@@ -3483,7 +3518,7 @@ svn_wc__conflict_tree_update_break_moved_away(svn_wc_context_t *wc_ctx,
return SVN_NO_ERROR;
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
- &src_op_root_abspath,
+ &src_op_root_abspath, NULL,
wc_ctx->db, local_abspath,
conflict_skel,
scratch_pool, scratch_pool));
@@ -3569,7 +3604,7 @@ svn_wc__conflict_tree_update_raise_moved_away(svn_wc_context_t *wc_ctx,
if (!tree_conflicted)
return SVN_NO_ERROR;
- SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL,
+ SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL, NULL,
wc_ctx->db, local_abspath,
conflict_skel,
scratch_pool, scratch_pool));
@@ -3648,7 +3683,7 @@ svn_wc__conflict_tree_update_moved_away_node(svn_wc_context_t *wc_ctx,
return SVN_NO_ERROR;
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
- &src_op_root_abspath,
+ &src_op_root_abspath, NULL,
wc_ctx->db, local_abspath,
conflict_skel,
scratch_pool, scratch_pool));
@@ -3734,8 +3769,8 @@ svn_wc__conflict_tree_update_incoming_move(svn_wc_context_t *wc_ctx,
return SVN_NO_ERROR;
SVN_ERR(svn_wc__conflict_read_tree_conflict(&local_change, &incoming_change,
- NULL, wc_ctx->db, local_abspath,
- conflict_skel,
+ NULL, NULL, wc_ctx->db,
+ local_abspath, conflict_skel,
scratch_pool, scratch_pool));
/* Make sure the expected conflict is recorded. */
@@ -3803,8 +3838,8 @@ svn_wc__conflict_tree_update_local_add(svn_wc_context_t *wc_ctx,
return SVN_NO_ERROR;
SVN_ERR(svn_wc__conflict_read_tree_conflict(&local_change, &incoming_change,
- NULL, wc_ctx->db, local_abspath,
- conflict_skel,
+ NULL, NULL, wc_ctx->db,
+ local_abspath, conflict_skel,
scratch_pool, scratch_pool));
/* Make sure the expected conflict is recorded. */
@@ -3853,9 +3888,9 @@ svn_wc__guess_incoming_move_target_nodes(apr_array_header_t **possible_targets,
apr_size_t longest_ancestor_len = 0;
*possible_targets = apr_array_make(result_pool, 1, sizeof(const char *));
- SVN_ERR(svn_wc__find_repos_node_in_wc(&candidates, wc_ctx->db, victim_abspath,
- moved_to_repos_relpath,
- scratch_pool, scratch_pool));
+ SVN_ERR(svn_wc__db_find_repos_node_in_wc(&candidates, wc_ctx->db, victim_abspath,
+ moved_to_repos_relpath,
+ scratch_pool, scratch_pool));
/* Find a "useful move target" node in our set of candidates.
* Since there is no way to be certain, filter out nodes which seem
@@ -3903,7 +3938,7 @@ svn_wc__guess_incoming_move_target_nodes(apr_array_header_t **possible_targets,
status != svn_wc__db_status_added)
continue;
- if (node_kind != victim_node_kind)
+ if (victim_node_kind != svn_node_none && node_kind != victim_node_kind)
continue;
SVN_ERR(svn_wc__db_is_switched(&is_wcroot, &is_switched, NULL,
@@ -3930,8 +3965,8 @@ svn_wc__guess_incoming_move_target_nodes(apr_array_header_t **possible_targets,
{
insert_index = (*possible_targets)->nelts; /* append */
}
- svn_sort__array_insert(*possible_targets, &moved_to_abspath,
- insert_index);
+ SVN_ERR(svn_sort__array_insert2(*possible_targets, &moved_to_abspath,
+ insert_index));
}
svn_pool_destroy(iterpool);
diff --git a/subversion/libsvn_wc/conflicts.h b/subversion/libsvn_wc/conflicts.h
index 0a9324b89a61..a5664571b308 100644
--- a/subversion/libsvn_wc/conflicts.h
+++ b/subversion/libsvn_wc/conflicts.h
@@ -219,6 +219,11 @@ svn_wc__conflict_skel_add_prop_conflict(svn_skel_t *conflict_skel,
MOVE_SRC_OP_ROOT_ABSPATH should be A for a conflict associated
with (1), MOVE_SRC_OP_ROOT_ABSPATH should be A/B for a conflict
associated with (2).
+ MOVE_DST_OP_ROOT_ABSPATH is the op-root of the move target (i.e. the
+ op-root of the corresponding copy). This needs to be stored because
+ moves in the NODE table do not always persist after an update, while
+ the conflict resolver may need information about the pre-update state
+ of the move.
It is an error to add another tree conflict to a conflict skel that
already contains a tree conflict. (It is not an error, at this level,
@@ -233,6 +238,7 @@ svn_wc__conflict_skel_add_tree_conflict(svn_skel_t *conflict_skel,
svn_wc_conflict_reason_t local_change,
svn_wc_conflict_action_t incoming_change,
const char *move_src_op_root_abspath,
+ const char *move_dst_op_root_abspath,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
@@ -364,6 +370,7 @@ svn_error_t *
svn_wc__conflict_read_tree_conflict(svn_wc_conflict_reason_t *local_change,
svn_wc_conflict_action_t *incoming_change,
const char **move_src_op_root_abspath,
+ const char **move_dst_op_root_abspath,
svn_wc__db_t *db,
const char *wri_abspath,
const svn_skel_t *conflict_skel,
diff --git a/subversion/libsvn_wc/deprecated.c b/subversion/libsvn_wc/deprecated.c
index e54a86df903b..379564bd6da8 100644
--- a/subversion/libsvn_wc/deprecated.c
+++ b/subversion/libsvn_wc/deprecated.c
@@ -1091,6 +1091,33 @@ svn_wc_add(const char *path,
/*** From revert.c ***/
svn_error_t *
+svn_wc_revert5(svn_wc_context_t *wc_ctx,
+ const char *local_abspath,
+ svn_depth_t depth,
+ svn_boolean_t use_commit_times,
+ const apr_array_header_t *changelist_filter,
+ svn_boolean_t clear_changelists,
+ svn_boolean_t metadata_only,
+ svn_cancel_func_t cancel_func,
+ void *cancel_baton,
+ svn_wc_notify_func2_t notify_func,
+ void *notify_baton,
+ apr_pool_t *scratch_pool)
+{
+ SVN_ERR(svn_wc_revert6(wc_ctx, local_abspath,
+ depth,
+ use_commit_times,
+ changelist_filter,
+ clear_changelists,
+ metadata_only,
+ TRUE /*added_keep_local*/,
+ cancel_func, cancel_baton,
+ notify_func, notify_baton,
+ scratch_pool));
+ return SVN_NO_ERROR;
+}
+
+svn_error_t *
svn_wc_revert4(svn_wc_context_t *wc_ctx,
const char *local_abspath,
svn_depth_t depth,
@@ -2069,8 +2096,7 @@ svn_wc_get_diff_editor6(const svn_delta_editor_t **editor,
result_pool, scratch_pool));
if (reverse_order)
- diff_processor = svn_diff__tree_processor_reverse_create(
- diff_processor, NULL, result_pool);
+ diff_processor = svn_diff__tree_processor_reverse_create(diff_processor, result_pool);
if (! show_copies_as_adds)
diff_processor = svn_diff__tree_processor_copy_as_changed_create(
diff --git a/subversion/libsvn_wc/diff_local.c b/subversion/libsvn_wc/diff_local.c
index 61ec06767e3a..26f9c6836928 100644
--- a/subversion/libsvn_wc/diff_local.c
+++ b/subversion/libsvn_wc/diff_local.c
@@ -433,8 +433,7 @@ diff_status_callback(void *baton,
/* Public Interface */
svn_error_t *
-svn_wc__diff7(const char **root_relpath,
- svn_boolean_t *root_is_dir,
+svn_wc__diff7(svn_boolean_t anchor_at_given_paths,
svn_wc_context_t *wc_ctx,
const char *local_abspath,
svn_depth_t depth,
@@ -459,26 +458,30 @@ svn_wc__diff7(const char **root_relpath,
eb.anchor_abspath = local_abspath;
- if (root_relpath)
+ if (anchor_at_given_paths)
{
+ /* Anchor the underlying diff processor at the parent of
+ LOCAL_ABSPATH (if possible), and adjust so the outgoing
+ DIFF_PROCESSOR is always anchored at LOCAL_ABSPATH. */
+ /* ### Why anchor the underlying diff processor at the parent? */
svn_boolean_t is_wcroot;
SVN_ERR(svn_wc__db_is_wcroot(&is_wcroot,
wc_ctx->db, local_abspath, scratch_pool));
if (!is_wcroot)
- eb.anchor_abspath = svn_dirent_dirname(local_abspath, scratch_pool);
+ {
+ const char *relpath;
+
+ eb.anchor_abspath = svn_dirent_dirname(local_abspath, scratch_pool);
+ relpath = svn_dirent_basename(local_abspath, NULL);
+ diff_processor = svn_diff__tree_processor_filter_create(
+ diff_processor, relpath, scratch_pool);
+ }
}
else if (kind != svn_node_dir)
eb.anchor_abspath = svn_dirent_dirname(local_abspath, scratch_pool);
- if (root_relpath)
- *root_relpath = apr_pstrdup(result_pool,
- svn_dirent_skip_ancestor(eb.anchor_abspath,
- local_abspath));
- if (root_is_dir)
- *root_is_dir = (kind == svn_node_dir);
-
/* Apply changelist filtering to the output */
if (changelist_filter && changelist_filter->nelts)
{
@@ -487,7 +490,7 @@ svn_wc__diff7(const char **root_relpath,
SVN_ERR(svn_hash_from_cstring_keys(&changelist_hash, changelist_filter,
result_pool));
diff_processor = svn_wc__changelist_filter_tree_processor_create(
- diff_processor, wc_ctx, local_abspath,
+ diff_processor, wc_ctx, eb.anchor_abspath,
changelist_hash, result_pool);
}
@@ -572,7 +575,7 @@ svn_wc_diff6(svn_wc_context_t *wc_ctx,
processor = svn_diff__tree_processor_copy_as_changed_create(processor,
scratch_pool);
- return svn_error_trace(svn_wc__diff7(NULL, NULL,
+ return svn_error_trace(svn_wc__diff7(FALSE,
wc_ctx, local_abspath,
depth,
ignore_ancestry,
diff --git a/subversion/libsvn_wc/entries.c b/subversion/libsvn_wc/entries.c
index 5748aa3cb857..c7e3ae0ae963 100644
--- a/subversion/libsvn_wc/entries.c
+++ b/subversion/libsvn_wc/entries.c
@@ -781,7 +781,7 @@ read_one_entry(const svn_wc_entry_t **new_entry,
if (parent_root_url != NULL
&& strcmp(original_root_url, parent_root_url) == 0)
{
-
+
const char *relpath_to_entry = svn_dirent_is_child(
op_root_abspath, entry_abspath, NULL);
const char *entry_repos_relpath = svn_relpath_join(
@@ -1049,7 +1049,7 @@ read_entries_new(apr_hash_t **result_entries,
svn_pool_clear(iterpool);
SVN_ERR(read_one_entry(&entry,
- db, dir_abspath,
+ db, dir_abspath,
wcroot, dir_relpath,
name, parent_entry,
result_pool, iterpool));
diff --git a/subversion/libsvn_wc/libsvn_wc.pc.in b/subversion/libsvn_wc/libsvn_wc.pc.in
index f44387e7472b..dc1c4d759aed 100644
--- a/subversion/libsvn_wc/libsvn_wc.pc.in
+++ b/subversion/libsvn_wc/libsvn_wc.pc.in
@@ -6,7 +6,7 @@ includedir=@includedir@
Name: libsvn_wc
Description: Subversion Working Copy Library
Version: @PACKAGE_VERSION@
-Requires: apr-util-@SVN_APR_MAJOR_VERSION@ apr-@SVN_APR_MAJOR_VERSION@
-Requires.private: libsvn_delta libsvn_diff libsvn_subr
-Libs: -L${libdir} -lsvn_wc
-Cflags: -I${includedir}
+Requires: apr-util-@SVN_APR_MAJOR_VERSION@, apr-@SVN_APR_MAJOR_VERSION@
+Requires.private: libsvn_delta, libsvn_diff, libsvn_subr
+Libs: -L${libdir} -lsvn_wc-1
+Cflags: -I${includedir}/subversion-1
diff --git a/subversion/libsvn_wc/node.c b/subversion/libsvn_wc/node.c
index 586477637274..71f0e48e38ba 100644
--- a/subversion/libsvn_wc/node.c
+++ b/subversion/libsvn_wc/node.c
@@ -1126,3 +1126,31 @@ svn_wc__node_was_moved_here(const char **moved_from_abspath,
return SVN_NO_ERROR;
}
+
+svn_error_t *
+svn_wc__find_working_nodes_with_basename(apr_array_header_t **abspaths,
+ const char *wri_abspath,
+ const char *basename,
+ svn_node_kind_t kind,
+ svn_wc_context_t *wc_ctx,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
+{
+ return svn_error_trace(svn_wc__db_find_working_nodes_with_basename(
+ abspaths, wc_ctx->db, wri_abspath, basename, kind,
+ result_pool, scratch_pool));
+}
+
+svn_error_t *
+svn_wc__find_copies_of_repos_path(apr_array_header_t **abspaths,
+ const char *wri_abspath,
+ const char *repos_relpath,
+ svn_node_kind_t kind,
+ svn_wc_context_t *wc_ctx,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
+{
+ return svn_error_trace(svn_wc__db_find_copies_of_repos_path(
+ abspaths, wc_ctx->db, wri_abspath, repos_relpath,
+ kind, result_pool, scratch_pool));
+}
diff --git a/subversion/libsvn_wc/props.c b/subversion/libsvn_wc/props.c
index f56899d86002..b314a34acf8f 100644
--- a/subversion/libsvn_wc/props.c
+++ b/subversion/libsvn_wc/props.c
@@ -2236,7 +2236,9 @@ svn_wc_canonicalize_svn_prop(const svn_string_t **propval_p,
if (duplicate_targets->nelts > 1)
{
more_str = apr_psprintf(/*scratch_*/pool,
- _(" (%d more duplicate targets found)"),
+ Q_(" (%d more duplicate target found)",
+ " (%d more duplicate targets found)",
+ duplicate_targets->nelts - 1),
duplicate_targets->nelts - 1);
}
return svn_error_createf(
diff --git a/subversion/libsvn_wc/questions.c b/subversion/libsvn_wc/questions.c
index 08583639b571..c248f5d63adc 100644
--- a/subversion/libsvn_wc/questions.c
+++ b/subversion/libsvn_wc/questions.c
@@ -475,7 +475,7 @@ internal_conflicted_p(svn_boolean_t *text_conflicted_p,
svn_wc_conflict_action_t action;
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action, NULL,
- db, local_abspath,
+ NULL, db, local_abspath,
conflicts,
scratch_pool,
scratch_pool));
diff --git a/subversion/libsvn_wc/revert.c b/subversion/libsvn_wc/revert.c
index bba1799864ab..28a17f091a82 100644
--- a/subversion/libsvn_wc/revert.c
+++ b/subversion/libsvn_wc/revert.c
@@ -62,6 +62,18 @@
the addition of all the directory's children. Again,
svn_wc_remove_from_revision_control() should do the trick.
+ - For a copy, we remove the item from disk as well. The thinking here
+ is that Subversion is responsible for the existence of the item: it
+ must have been created by something like 'svn copy' or 'svn merge'.
+
+ - For a plain add, removing the file or directory from disk is optional.
+ The user's idea of Subversion's involvement could be either that
+ Subversion was just responsible for adding an existing item to version
+ control, as with 'svn add', and so should not be responsible for
+ deleting it from disk; or that Subversion is responsible for the
+ existence of the item, e.g. if created by 'svn patch' or svn mkdir'.
+ It depends on the use case.
+
Deletes
- Restore properties to their unmodified state.
@@ -285,6 +297,7 @@ revert_restore(svn_boolean_t *run_wq,
svn_boolean_t metadata_only,
svn_boolean_t use_commit_times,
svn_boolean_t revert_root,
+ svn_boolean_t added_keep_local,
const struct svn_wc__db_info_t *info,
svn_cancel_func_t cancel_func,
void *cancel_baton,
@@ -344,8 +357,9 @@ revert_restore(svn_boolean_t *run_wq,
}
else
{
- if (!copied_here)
+ if (added_keep_local && !copied_here)
{
+ /* It is a plain add, and we want to keep the local file/dir. */
if (notify_func && notify_required)
notify_func(notify_baton,
svn_wc_create_notify(local_abspath,
@@ -359,8 +373,17 @@ revert_restore(svn_boolean_t *run_wq,
scratch_pool));
return SVN_NO_ERROR;
}
+ else if (!copied_here)
+ {
+ /* It is a plain add, and we don't want to keep the local file/dir. */
+ status = svn_wc__db_status_not_present;
+ kind = svn_node_none;
+ recorded_size = SVN_INVALID_FILESIZE;
+ recorded_time = 0;
+ }
else
{
+ /* It is a copy, so we don't want to keep the local file/dir. */
/* ### Initialise to values which prevent the code below from
* ### trying to restore anything to disk.
* ### 'status' should be status_unknown but that doesn't exist. */
@@ -429,6 +452,7 @@ revert_restore(svn_boolean_t *run_wq,
SVN_ERR(revert_restore(run_wq,
db, child_abspath, depth, metadata_only,
use_commit_times, FALSE /* revert root */,
+ added_keep_local,
apr_hash_this_val(hi),
cancel_func, cancel_baton,
notify_func, notify_baton,
@@ -536,11 +560,7 @@ revert_wc_data(svn_boolean_t *run_wq,
/* If we expect a versioned item to be present then check that any
item on disk matches the versioned item, if it doesn't match then
fix it or delete it. */
- if (on_disk != svn_node_none
- && status != svn_wc__db_status_server_excluded
- && status != svn_wc__db_status_deleted
- && status != svn_wc__db_status_excluded
- && status != svn_wc__db_status_not_present)
+ if (on_disk != svn_node_none)
{
if (on_disk == svn_node_dir && kind != svn_node_dir)
{
@@ -560,7 +580,11 @@ revert_wc_data(svn_boolean_t *run_wq,
on_disk = svn_node_none;
}
}
- else if (on_disk == svn_node_file)
+ else if (on_disk == svn_node_file
+ && status != svn_wc__db_status_server_excluded
+ && status != svn_wc__db_status_deleted
+ && status != svn_wc__db_status_excluded
+ && status != svn_wc__db_status_not_present)
{
svn_boolean_t modified;
apr_hash_t *props;
@@ -712,6 +736,7 @@ revert(svn_wc__db_t *db,
svn_boolean_t use_commit_times,
svn_boolean_t clear_changelists,
svn_boolean_t metadata_only,
+ svn_boolean_t added_keep_local,
svn_cancel_func_t cancel_func,
void *cancel_baton,
svn_wc_notify_func2_t notify_func,
@@ -762,6 +787,7 @@ revert(svn_wc__db_t *db,
err = svn_error_trace(
revert_restore(&run_queue, db, local_abspath, depth, metadata_only,
use_commit_times, TRUE /* revert root */,
+ added_keep_local,
info, cancel_func, cancel_baton,
notify_func, notify_baton,
scratch_pool));
@@ -791,6 +817,7 @@ revert_changelist(svn_wc__db_t *db,
apr_hash_t *changelist_hash,
svn_boolean_t clear_changelists,
svn_boolean_t metadata_only,
+ svn_boolean_t added_keep_local,
svn_cancel_func_t cancel_func,
void *cancel_baton,
svn_wc_notify_func2_t notify_func,
@@ -809,7 +836,7 @@ revert_changelist(svn_wc__db_t *db,
scratch_pool))
SVN_ERR(revert(db, local_abspath,
svn_depth_empty, use_commit_times, clear_changelists,
- metadata_only,
+ metadata_only, added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
scratch_pool));
@@ -845,6 +872,7 @@ revert_changelist(svn_wc__db_t *db,
SVN_ERR(revert_changelist(db, child_abspath, depth,
use_commit_times, changelist_hash,
clear_changelists, metadata_only,
+ added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
iterpool));
@@ -871,6 +899,7 @@ revert_partial(svn_wc__db_t *db,
svn_boolean_t use_commit_times,
svn_boolean_t clear_changelists,
svn_boolean_t metadata_only,
+ svn_boolean_t added_keep_local,
svn_cancel_func_t cancel_func,
void *cancel_baton,
svn_wc_notify_func2_t notify_func,
@@ -892,6 +921,7 @@ revert_partial(svn_wc__db_t *db,
children. */
SVN_ERR(revert(db, local_abspath, svn_depth_empty,
use_commit_times, clear_changelists, metadata_only,
+ added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton, iterpool));
@@ -926,7 +956,7 @@ revert_partial(svn_wc__db_t *db,
/* Revert just this node (depth=empty). */
SVN_ERR(revert(db, child_abspath,
svn_depth_empty, use_commit_times, clear_changelists,
- metadata_only,
+ metadata_only, added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
iterpool));
@@ -939,13 +969,14 @@ revert_partial(svn_wc__db_t *db,
svn_error_t *
-svn_wc_revert5(svn_wc_context_t *wc_ctx,
+svn_wc_revert6(svn_wc_context_t *wc_ctx,
const char *local_abspath,
svn_depth_t depth,
svn_boolean_t use_commit_times,
const apr_array_header_t *changelist_filter,
svn_boolean_t clear_changelists,
svn_boolean_t metadata_only,
+ svn_boolean_t added_keep_local,
svn_cancel_func_t cancel_func,
void *cancel_baton,
svn_wc_notify_func2_t notify_func,
@@ -963,6 +994,7 @@ svn_wc_revert5(svn_wc_context_t *wc_ctx,
changelist_hash,
clear_changelists,
metadata_only,
+ added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
scratch_pool));
@@ -972,6 +1004,7 @@ svn_wc_revert5(svn_wc_context_t *wc_ctx,
return svn_error_trace(revert(wc_ctx->db, local_abspath,
depth, use_commit_times, clear_changelists,
metadata_only,
+ added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
scratch_pool));
@@ -986,6 +1019,7 @@ svn_wc_revert5(svn_wc_context_t *wc_ctx,
return svn_error_trace(revert_partial(wc_ctx->db, local_abspath,
depth, use_commit_times,
clear_changelists, metadata_only,
+ added_keep_local,
cancel_func, cancel_baton,
notify_func, notify_baton,
scratch_pool));
diff --git a/subversion/libsvn_wc/tree_conflicts.c b/subversion/libsvn_wc/tree_conflicts.c
index caf39eda9878..e8465775a61c 100644
--- a/subversion/libsvn_wc/tree_conflicts.c
+++ b/subversion/libsvn_wc/tree_conflicts.c
@@ -442,7 +442,7 @@ svn_wc__add_tree_conflict(svn_wc_context_t *wc_ctx,
conflict->local_abspath,
conflict->reason,
conflict->action,
- NULL,
+ NULL, NULL,
scratch_pool, scratch_pool));
switch (conflict->operation)
diff --git a/subversion/libsvn_wc/update_editor.c b/subversion/libsvn_wc/update_editor.c
index 4dca3af7e13f..307356162148 100644
--- a/subversion/libsvn_wc/update_editor.c
+++ b/subversion/libsvn_wc/update_editor.c
@@ -1235,9 +1235,11 @@ open_root(void *edit_baton,
db->shadowed = TRUE;
else if (have_work)
{
+ const char *move_dst_op_root_abspath;
const char *move_src_root_abspath;
- SVN_ERR(svn_wc__db_base_moved_to(NULL, NULL, &move_src_root_abspath,
+ SVN_ERR(svn_wc__db_base_moved_to(NULL, &move_dst_op_root_abspath,
+ &move_src_root_abspath,
NULL, eb->db, db->local_abspath,
pool, pool));
@@ -1252,7 +1254,8 @@ open_root(void *edit_baton,
tree_conflict, eb->db, move_src_root_abspath,
svn_wc_conflict_reason_moved_away,
svn_wc_conflict_action_edit,
- move_src_root_abspath, pool, pool));
+ move_src_root_abspath,
+ move_dst_op_root_abspath, pool, pool));
if (strcmp(db->local_abspath, move_src_root_abspath))
{
@@ -1345,6 +1348,7 @@ check_tree_conflict(svn_skel_t **pconflict,
svn_wc_conflict_reason_t reason = SVN_WC_CONFLICT_REASON_NONE;
svn_boolean_t modified = FALSE;
const char *move_src_op_root_abspath = NULL;
+ const char *move_dst_op_root_abspath = NULL;
*pconflict = NULL;
@@ -1397,8 +1401,8 @@ check_tree_conflict(svn_skel_t **pconflict,
case svn_wc__db_status_deleted:
{
- SVN_ERR(svn_wc__db_base_moved_to(NULL, NULL, NULL,
- &move_src_op_root_abspath,
+ SVN_ERR(svn_wc__db_base_moved_to(NULL, &move_dst_op_root_abspath,
+ NULL, &move_src_op_root_abspath,
eb->db, local_abspath,
scratch_pool, scratch_pool));
if (move_src_op_root_abspath)
@@ -1454,7 +1458,7 @@ check_tree_conflict(svn_skel_t **pconflict,
* Therefore, we need to start a separate crawl here. */
SVN_ERR(svn_wc__node_has_local_mods(&modified, NULL,
- eb->db, local_abspath, FALSE,
+ eb->db, local_abspath, TRUE,
eb->cancel_func, eb->cancel_baton,
scratch_pool));
@@ -1530,6 +1534,7 @@ check_tree_conflict(svn_skel_t **pconflict,
reason,
action,
move_src_op_root_abspath,
+ move_dst_op_root_abspath,
result_pool, scratch_pool));
return SVN_NO_ERROR;
@@ -2007,11 +2012,13 @@ add_directory(const char *path,
{
svn_wc_conflict_reason_t reason;
const char *move_src_op_root_abspath;
+ const char *move_dst_op_root_abspath;
/* So this deletion wasn't just a deletion, it is actually a
replacement. Let's install a better tree conflict. */
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL,
&move_src_op_root_abspath,
+ &move_dst_op_root_abspath,
eb->db,
db->local_abspath,
tree_conflict,
@@ -2024,6 +2031,7 @@ add_directory(const char *path,
eb->db, db->local_abspath,
reason, svn_wc_conflict_action_replace,
move_src_op_root_abspath,
+ move_dst_op_root_abspath,
db->pool, scratch_pool));
/* And now stop checking for conflicts here and just perform
@@ -2148,8 +2156,8 @@ add_directory(const char *path,
tree_conflict,
eb->db, db->local_abspath,
svn_wc_conflict_reason_unversioned,
- svn_wc_conflict_action_add, NULL,
- db->pool, scratch_pool));
+ svn_wc_conflict_action_add,
+ NULL, NULL, db->pool, scratch_pool));
db->edit_conflict = tree_conflict;
}
}
@@ -2336,7 +2344,7 @@ open_directory(const char *path,
db->edit_conflict = tree_conflict;
/* Other modifications wouldn't be a tree conflict */
- SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL,
+ SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL, NULL,
eb->db, db->local_abspath,
tree_conflict,
db->pool, db->pool));
@@ -3220,11 +3228,13 @@ add_file(const char *path,
{
svn_wc_conflict_reason_t reason;
const char *move_src_op_root_abspath;
+ const char *move_dst_op_root_abspath;
/* So this deletion wasn't just a deletion, it is actually a
replacement. Let's install a better tree conflict. */
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL,
&move_src_op_root_abspath,
+ &move_dst_op_root_abspath,
eb->db,
fb->local_abspath,
tree_conflict,
@@ -3237,6 +3247,7 @@ add_file(const char *path,
eb->db, fb->local_abspath,
reason, svn_wc_conflict_action_replace,
move_src_op_root_abspath,
+ move_dst_op_root_abspath,
fb->pool, scratch_pool));
/* And now stop checking for conflicts here and just perform
@@ -3363,7 +3374,7 @@ add_file(const char *path,
eb->db, fb->local_abspath,
svn_wc_conflict_reason_unversioned,
svn_wc_conflict_action_add,
- NULL,
+ NULL, NULL,
fb->pool, scratch_pool));
}
}
@@ -3528,7 +3539,7 @@ open_file(const char *path,
fb->edit_conflict = tree_conflict;
/* Other modifications wouldn't be a tree conflict */
- SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL,
+ SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, NULL, NULL, NULL,
eb->db, fb->local_abspath,
tree_conflict,
scratch_pool, scratch_pool));
@@ -3797,7 +3808,7 @@ change_file_prop(void *file_baton,
eb->db, fb->local_abspath,
svn_wc_conflict_reason_edited,
svn_wc_conflict_action_replace,
- NULL,
+ NULL, NULL,
fb->pool, scratch_pool));
SVN_ERR(complete_conflict(fb->edit_conflict, fb->edit_baton,
diff --git a/subversion/libsvn_wc/upgrade.c b/subversion/libsvn_wc/upgrade.c
index 3b9ab3a35319..67791c60845d 100644
--- a/subversion/libsvn_wc/upgrade.c
+++ b/subversion/libsvn_wc/upgrade.c
@@ -1237,7 +1237,7 @@ svn_wc__upgrade_conflict_skel_from_raw(svn_skel_t **conflicts,
db, wri_abspath,
tc->reason,
tc->action,
- NULL,
+ NULL, NULL,
scratch_pool,
scratch_pool));
@@ -1667,7 +1667,7 @@ svn_wc__upgrade_sdb(int *result_format,
"use the current client"),
svn_dirent_local_style(wcroot_abspath,
scratch_pool),
- start_format);
+ start_format);
/* ### need lock-out. only one upgrade at a time. note that other code
### cannot use this un-upgraded database until we finish the upgrade. */
diff --git a/subversion/libsvn_wc/wc-checks.h b/subversion/libsvn_wc/wc-checks.h
index bb9e5493a367..162bca4844df 100644
--- a/subversion/libsvn_wc/wc-checks.h
+++ b/subversion/libsvn_wc/wc-checks.h
@@ -1,4 +1,4 @@
-/* This file is automatically generated from wc-checks.sql and /opt/svnrm/tempdir/subversion-1.10.2/subversion/libsvn_wc/token-map.h.
+/* This file is automatically generated from wc-checks.sql and token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_VERIFICATION_TRIGGERS 0
diff --git a/subversion/libsvn_wc/wc-metadata.h b/subversion/libsvn_wc/wc-metadata.h
index 7c7c78b45a45..75e7503c3f3f 100644
--- a/subversion/libsvn_wc/wc-metadata.h
+++ b/subversion/libsvn_wc/wc-metadata.h
@@ -1,4 +1,4 @@
-/* This file is automatically generated from wc-metadata.sql and /opt/svnrm/tempdir/subversion-1.10.2/subversion/libsvn_wc/token-map.h.
+/* This file is automatically generated from wc-metadata.sql and token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_CREATE_SCHEMA 0
diff --git a/subversion/libsvn_wc/wc-queries.h b/subversion/libsvn_wc/wc-queries.h
index b333e95ffdbe..b6254e1a5bca 100644
--- a/subversion/libsvn_wc/wc-queries.h
+++ b/subversion/libsvn_wc/wc-queries.h
@@ -1,4 +1,4 @@
-/* This file is automatically generated from wc-queries.sql and subversion/libsvn_wc/token-map.h.
+/* This file is automatically generated from wc-queries.sql and token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_SELECT_NODE_INFO 0
@@ -115,17 +115,31 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_ACTUAL_NODE 10
-#define STMT_10_INFO {"STMT_SELECT_ACTUAL_NODE", NULL}
+#define STMT_SELECT_PRESENT_HIGHEST_WORKING_NODES_BY_BASENAME_AND_KIND 10
+#define STMT_10_INFO {"STMT_SELECT_PRESENT_HIGHEST_WORKING_NODES_BY_BASENAME_AND_KIND", NULL}
#define STMT_10 \
+ "SELECT presence, local_relpath " \
+ "FROM nodes n " \
+ "WHERE wc_id = ?1 AND local_relpath = (CASE WHEN (parent_relpath) = '' THEN (?2) WHEN (?2) = '' THEN (parent_relpath) ELSE (parent_relpath) || '/' || (?2) END) " \
+ " AND kind = ?3 " \
+ " AND presence in ('normal', 'incomplete') " \
+ " AND op_depth = (SELECT MAX(op_depth) " \
+ " FROM NODES w " \
+ " WHERE w.wc_id = ?1 " \
+ " AND w.local_relpath = n.local_relpath) " \
+ ""
+
+#define STMT_SELECT_ACTUAL_NODE 11
+#define STMT_11_INFO {"STMT_SELECT_ACTUAL_NODE", NULL}
+#define STMT_11 \
"SELECT changelist, properties, conflict_data " \
"FROM actual_node " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_SELECT_NODE_CHILDREN_INFO 11
-#define STMT_11_INFO {"STMT_SELECT_NODE_CHILDREN_INFO", NULL}
-#define STMT_11 \
+#define STMT_SELECT_NODE_CHILDREN_INFO 12
+#define STMT_12_INFO {"STMT_SELECT_NODE_CHILDREN_INFO", NULL}
+#define STMT_12 \
"SELECT op_depth, nodes.repos_id, nodes.repos_path, presence, kind, revision, " \
" checksum, translated_size, changed_revision, changed_date, changed_author, " \
" depth, symlink_target, last_mod_time, properties, lock_token, lock_owner, " \
@@ -137,9 +151,9 @@
"ORDER BY local_relpath DESC, op_depth DESC " \
""
-#define STMT_SELECT_BASE_NODE_CHILDREN_INFO 12
-#define STMT_12_INFO {"STMT_SELECT_BASE_NODE_CHILDREN_INFO", NULL}
-#define STMT_12 \
+#define STMT_SELECT_BASE_NODE_CHILDREN_INFO 13
+#define STMT_13_INFO {"STMT_SELECT_BASE_NODE_CHILDREN_INFO", NULL}
+#define STMT_13 \
"SELECT op_depth, nodes.repos_id, nodes.repos_path, presence, kind, revision, " \
" checksum, translated_size, changed_revision, changed_date, changed_author, " \
" depth, symlink_target, last_mod_time, properties, lock_token, lock_owner, " \
@@ -151,50 +165,50 @@
"ORDER BY local_relpath DESC " \
""
-#define STMT_SELECT_NODE_CHILDREN_WALKER_INFO 13
-#define STMT_13_INFO {"STMT_SELECT_NODE_CHILDREN_WALKER_INFO", NULL}
-#define STMT_13 \
+#define STMT_SELECT_NODE_CHILDREN_WALKER_INFO 14
+#define STMT_14_INFO {"STMT_SELECT_NODE_CHILDREN_WALKER_INFO", NULL}
+#define STMT_14 \
"SELECT local_relpath, op_depth, presence, kind " \
"FROM nodes_current " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_ACTUAL_CHILDREN_INFO 14
-#define STMT_14_INFO {"STMT_SELECT_ACTUAL_CHILDREN_INFO", NULL}
-#define STMT_14 \
+#define STMT_SELECT_ACTUAL_CHILDREN_INFO 15
+#define STMT_15_INFO {"STMT_SELECT_ACTUAL_CHILDREN_INFO", NULL}
+#define STMT_15 \
"SELECT local_relpath, changelist, properties, conflict_data " \
"FROM actual_node " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
""
-#define STMT_SELECT_REPOSITORY_BY_ID 15
-#define STMT_15_INFO {"STMT_SELECT_REPOSITORY_BY_ID", NULL}
-#define STMT_15 \
+#define STMT_SELECT_REPOSITORY_BY_ID 16
+#define STMT_16_INFO {"STMT_SELECT_REPOSITORY_BY_ID", NULL}
+#define STMT_16 \
"SELECT root, uuid FROM repository WHERE id = ?1 " \
""
-#define STMT_SELECT_WCROOT_NULL 16
-#define STMT_16_INFO {"STMT_SELECT_WCROOT_NULL", NULL}
-#define STMT_16 \
+#define STMT_SELECT_WCROOT_NULL 17
+#define STMT_17_INFO {"STMT_SELECT_WCROOT_NULL", NULL}
+#define STMT_17 \
"SELECT id FROM wcroot WHERE local_abspath IS NULL " \
""
-#define STMT_SELECT_REPOSITORY 17
-#define STMT_17_INFO {"STMT_SELECT_REPOSITORY", NULL}
-#define STMT_17 \
+#define STMT_SELECT_REPOSITORY 18
+#define STMT_18_INFO {"STMT_SELECT_REPOSITORY", NULL}
+#define STMT_18 \
"SELECT id FROM repository WHERE root = ?1 " \
""
-#define STMT_INSERT_REPOSITORY 18
-#define STMT_18_INFO {"STMT_INSERT_REPOSITORY", NULL}
-#define STMT_18 \
+#define STMT_INSERT_REPOSITORY 19
+#define STMT_19_INFO {"STMT_INSERT_REPOSITORY", NULL}
+#define STMT_19 \
"INSERT INTO repository (root, uuid) VALUES (?1, ?2) " \
""
-#define STMT_INSERT_NODE 19
-#define STMT_19_INFO {"STMT_INSERT_NODE", NULL}
-#define STMT_19 \
+#define STMT_INSERT_NODE 20
+#define STMT_20_INFO {"STMT_INSERT_NODE", NULL}
+#define STMT_20 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, repos_path, " \
" revision, presence, depth, kind, changed_revision, changed_date, " \
@@ -205,9 +219,9 @@
" ?15, ?16, ?17, ?18, ?19, ?20, ?21, ?22, ?23) " \
""
-#define STMT_SELECT_WORKING_PRESENT 20
-#define STMT_20_INFO {"STMT_SELECT_WORKING_PRESENT", NULL}
-#define STMT_20 \
+#define STMT_SELECT_WORKING_PRESENT 21
+#define STMT_21_INFO {"STMT_SELECT_WORKING_PRESENT", NULL}
+#define STMT_21 \
"SELECT local_relpath, kind, checksum, translated_size, last_mod_time " \
"FROM nodes n " \
"WHERE wc_id = ?1 " \
@@ -220,25 +234,25 @@
"ORDER BY local_relpath DESC " \
""
-#define STMT_DELETE_NODE_RECURSIVE 21
-#define STMT_21_INFO {"STMT_DELETE_NODE_RECURSIVE", NULL}
-#define STMT_21 \
+#define STMT_DELETE_NODE_RECURSIVE 22
+#define STMT_22_INFO {"STMT_DELETE_NODE_RECURSIVE", NULL}
+#define STMT_22 \
"DELETE FROM NODES " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_DELETE_NODE 22
-#define STMT_22_INFO {"STMT_DELETE_NODE", NULL}
-#define STMT_22 \
+#define STMT_DELETE_NODE 23
+#define STMT_23_INFO {"STMT_DELETE_NODE", NULL}
+#define STMT_23 \
"DELETE " \
"FROM NODES " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?3 " \
""
-#define STMT_DELETE_ACTUAL_FOR_BASE_RECURSIVE 23
-#define STMT_23_INFO {"STMT_DELETE_ACTUAL_FOR_BASE_RECURSIVE", NULL}
-#define STMT_23 \
+#define STMT_DELETE_ACTUAL_FOR_BASE_RECURSIVE 24
+#define STMT_24_INFO {"STMT_DELETE_ACTUAL_FOR_BASE_RECURSIVE", NULL}
+#define STMT_24 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND EXISTS(SELECT 1 FROM NODES b " \
@@ -252,9 +266,9 @@
" AND presence in ('normal', 'incomplete', 'not-present')) " \
""
-#define STMT_DELETE_WORKING_BASE_DELETE 24
-#define STMT_24_INFO {"STMT_DELETE_WORKING_BASE_DELETE", NULL}
-#define STMT_24 \
+#define STMT_DELETE_WORKING_BASE_DELETE 25
+#define STMT_25_INFO {"STMT_DELETE_WORKING_BASE_DELETE", NULL}
+#define STMT_25 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
" AND presence = 'base-deleted' " \
@@ -265,9 +279,9 @@
" AND op_depth > ?3) " \
""
-#define STMT_DELETE_WORKING_BASE_DELETE_RECURSIVE 25
-#define STMT_25_INFO {"STMT_DELETE_WORKING_BASE_DELETE_RECURSIVE", NULL}
-#define STMT_25 \
+#define STMT_DELETE_WORKING_BASE_DELETE_RECURSIVE 26
+#define STMT_26_INFO {"STMT_DELETE_WORKING_BASE_DELETE_RECURSIVE", NULL}
+#define STMT_26 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND presence = 'base-deleted' " \
@@ -278,35 +292,35 @@
" AND op_depth > ?3) " \
""
-#define STMT_DELETE_WORKING_RECURSIVE 26
-#define STMT_26_INFO {"STMT_DELETE_WORKING_RECURSIVE", NULL}
-#define STMT_26 \
+#define STMT_DELETE_WORKING_RECURSIVE 27
+#define STMT_27_INFO {"STMT_DELETE_WORKING_RECURSIVE", NULL}
+#define STMT_27 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND op_depth > 0 " \
""
-#define STMT_DELETE_BASE_RECURSIVE 27
-#define STMT_27_INFO {"STMT_DELETE_BASE_RECURSIVE", NULL}
-#define STMT_27 \
+#define STMT_DELETE_BASE_RECURSIVE 28
+#define STMT_28_INFO {"STMT_DELETE_BASE_RECURSIVE", NULL}
+#define STMT_28 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND (local_relpath = ?2 " \
" OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
" AND op_depth = 0 " \
""
-#define STMT_DELETE_WORKING_OP_DEPTH 28
-#define STMT_28_INFO {"STMT_DELETE_WORKING_OP_DEPTH", NULL}
-#define STMT_28 \
+#define STMT_DELETE_WORKING_OP_DEPTH 29
+#define STMT_29_INFO {"STMT_DELETE_WORKING_OP_DEPTH", NULL}
+#define STMT_29 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
" AND op_depth = ?3 " \
""
-#define STMT_SELECT_LAYER_FOR_REPLACE 29
-#define STMT_29_INFO {"STMT_SELECT_LAYER_FOR_REPLACE", NULL}
-#define STMT_29 \
+#define STMT_SELECT_LAYER_FOR_REPLACE 30
+#define STMT_30_INFO {"STMT_SELECT_LAYER_FOR_REPLACE", NULL}
+#define STMT_30 \
"SELECT s.local_relpath, s.kind, " \
" (CASE WHEN (?2) = '' THEN (CASE WHEN (?4) = '' THEN (s.local_relpath) WHEN (s.local_relpath) = '' THEN (?4) ELSE (?4) || '/' || (s.local_relpath) END) WHEN (?4) = '' THEN (CASE WHEN (?2) = '' THEN (s.local_relpath) WHEN SUBSTR((s.local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(s.local_relpath) THEN '' WHEN SUBSTR((s.local_relpath), LENGTH(?2)+1, 1) = '/' THEN SUBSTR((s.local_relpath), LENGTH(?2)+2) END END) WHEN SUBSTR((s.local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(s.local_relpath) THEN (?4) WHEN SUBSTR((s.local_relpath), LENGTH(?2)+1, 1) = '/' THEN (?4) || SUBSTR((s.local_relpath), LENGTH(?2)+1) END END) drp, 'normal' " \
"FROM nodes s " \
@@ -323,9 +337,9 @@
"ORDER BY s.local_relpath " \
""
-#define STMT_SELECT_DESCENDANTS_OP_DEPTH_RV 30
-#define STMT_30_INFO {"STMT_SELECT_DESCENDANTS_OP_DEPTH_RV", NULL}
-#define STMT_30 \
+#define STMT_SELECT_DESCENDANTS_OP_DEPTH_RV 31
+#define STMT_31_INFO {"STMT_SELECT_DESCENDANTS_OP_DEPTH_RV", NULL}
+#define STMT_31 \
"SELECT local_relpath, kind " \
"FROM nodes " \
"WHERE wc_id = ?1 " \
@@ -335,9 +349,9 @@
"ORDER BY local_relpath DESC " \
""
-#define STMT_COPY_NODE_MOVE 31
-#define STMT_31_INFO {"STMT_COPY_NODE_MOVE", NULL}
-#define STMT_31 \
+#define STMT_COPY_NODE_MOVE 32
+#define STMT_32_INFO {"STMT_COPY_NODE_MOVE", NULL}
+#define STMT_32 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, repos_path, " \
" revision, presence, depth, kind, changed_revision, changed_date, " \
@@ -356,9 +370,9 @@
"WHERE s.wc_id = ?1 AND s.local_relpath = ?2 AND s.op_depth = ?3 " \
""
-#define STMT_SELECT_NO_LONGER_MOVED_RV 32
-#define STMT_32_INFO {"STMT_SELECT_NO_LONGER_MOVED_RV", NULL}
-#define STMT_32 \
+#define STMT_SELECT_NO_LONGER_MOVED_RV 33
+#define STMT_33_INFO {"STMT_SELECT_NO_LONGER_MOVED_RV", NULL}
+#define STMT_33 \
"SELECT d.local_relpath, (CASE WHEN (?2) = '' THEN (CASE WHEN (?4) = '' THEN (d.local_relpath) WHEN (d.local_relpath) = '' THEN (?4) ELSE (?4) || '/' || (d.local_relpath) END) WHEN (?4) = '' THEN (CASE WHEN (?2) = '' THEN (d.local_relpath) WHEN SUBSTR((d.local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(d.local_relpath) THEN '' WHEN SUBSTR((d.local_relpath), LENGTH(?2)+1, 1) = '/' THEN SUBSTR((d.local_relpath), LENGTH(?2)+2) END END) WHEN SUBSTR((d.local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(d.local_relpath) THEN (?4) WHEN SUBSTR((d.local_relpath), LENGTH(?2)+1, 1) = '/' THEN (?4) || SUBSTR((d.local_relpath), LENGTH(?2)+1) END END) srp, " \
" b.presence, b.op_depth " \
"FROM nodes d " \
@@ -377,9 +391,9 @@
"ORDER BY d.local_relpath DESC " \
""
-#define STMT_SELECT_OP_DEPTH_CHILDREN 33
-#define STMT_33_INFO {"STMT_SELECT_OP_DEPTH_CHILDREN", NULL}
-#define STMT_33 \
+#define STMT_SELECT_OP_DEPTH_CHILDREN 34
+#define STMT_34_INFO {"STMT_SELECT_OP_DEPTH_CHILDREN", NULL}
+#define STMT_34 \
"SELECT local_relpath, kind FROM nodes " \
"WHERE wc_id = ?1 " \
" AND parent_relpath = ?2 " \
@@ -389,9 +403,9 @@
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_OP_DEPTH_CHILDREN_EXISTS 34
-#define STMT_34_INFO {"STMT_SELECT_OP_DEPTH_CHILDREN_EXISTS", NULL}
-#define STMT_34 \
+#define STMT_SELECT_OP_DEPTH_CHILDREN_EXISTS 35
+#define STMT_35_INFO {"STMT_SELECT_OP_DEPTH_CHILDREN_EXISTS", NULL}
+#define STMT_35 \
"SELECT local_relpath, kind FROM nodes " \
"WHERE wc_id = ?1 " \
" AND parent_relpath = ?2 " \
@@ -400,9 +414,9 @@
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_GE_OP_DEPTH_CHILDREN 35
-#define STMT_35_INFO {"STMT_SELECT_GE_OP_DEPTH_CHILDREN", NULL}
-#define STMT_35 \
+#define STMT_SELECT_GE_OP_DEPTH_CHILDREN 36
+#define STMT_36_INFO {"STMT_SELECT_GE_OP_DEPTH_CHILDREN", NULL}
+#define STMT_36 \
"SELECT 1 FROM nodes " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
" AND (op_depth > ?3 OR (op_depth = ?3 " \
@@ -414,9 +428,9 @@
" WHERE wc_id = ?1 AND n.local_relpath = a.local_relpath) " \
""
-#define STMT_DELETE_SHADOWED_RECURSIVE 36
-#define STMT_36_INFO {"STMT_DELETE_SHADOWED_RECURSIVE", NULL}
-#define STMT_36 \
+#define STMT_DELETE_SHADOWED_RECURSIVE 37
+#define STMT_37_INFO {"STMT_DELETE_SHADOWED_RECURSIVE", NULL}
+#define STMT_37 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -424,26 +438,26 @@
" OR (op_depth = ?3 AND presence = 'base-deleted')) " \
""
-#define STMT_CLEAR_MOVED_TO_FROM_DEST 37
-#define STMT_37_INFO {"STMT_CLEAR_MOVED_TO_FROM_DEST", NULL}
-#define STMT_37 \
+#define STMT_CLEAR_MOVED_TO_FROM_DEST 38
+#define STMT_38_INFO {"STMT_CLEAR_MOVED_TO_FROM_DEST", NULL}
+#define STMT_38 \
"UPDATE NODES SET moved_to = NULL " \
"WHERE wc_id = ?1 " \
" AND moved_to = ?2 " \
""
-#define STMT_SELECT_NOT_PRESENT_DESCENDANTS 38
-#define STMT_38_INFO {"STMT_SELECT_NOT_PRESENT_DESCENDANTS", NULL}
-#define STMT_38 \
+#define STMT_SELECT_NOT_PRESENT_DESCENDANTS 39
+#define STMT_39_INFO {"STMT_SELECT_NOT_PRESENT_DESCENDANTS", NULL}
+#define STMT_39 \
"SELECT local_relpath FROM nodes " \
"WHERE wc_id = ?1 AND op_depth = ?3 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND presence = 'not-present' " \
""
-#define STMT_COMMIT_DESCENDANTS_TO_BASE 39
-#define STMT_39_INFO {"STMT_COMMIT_DESCENDANTS_TO_BASE", NULL}
-#define STMT_39 \
+#define STMT_COMMIT_DESCENDANTS_TO_BASE 40
+#define STMT_40_INFO {"STMT_COMMIT_DESCENDANTS_TO_BASE", NULL}
+#define STMT_40 \
"UPDATE NODES SET op_depth = 0, " \
" repos_id = ?4, " \
" repos_path = (CASE WHEN (?2) = '' THEN (CASE WHEN (?5) = '' THEN (local_relpath) WHEN (local_relpath) = '' THEN (?5) ELSE (?5) || '/' || (local_relpath) END) WHEN (?5) = '' THEN (CASE WHEN (?2) = '' THEN (local_relpath) WHEN SUBSTR((local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(local_relpath) THEN '' WHEN SUBSTR((local_relpath), LENGTH(?2)+1, 1) = '/' THEN SUBSTR((local_relpath), LENGTH(?2)+2) END END) WHEN SUBSTR((local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(local_relpath) THEN (?5) WHEN SUBSTR((local_relpath), LENGTH(?2)+1, 1) = '/' THEN (?5) || SUBSTR((local_relpath), LENGTH(?2)+1) END END), " \
@@ -461,17 +475,17 @@
" AND op_depth = ?3 " \
""
-#define STMT_SELECT_NODE_CHILDREN 40
-#define STMT_40_INFO {"STMT_SELECT_NODE_CHILDREN", NULL}
-#define STMT_40 \
+#define STMT_SELECT_NODE_CHILDREN 41
+#define STMT_41_INFO {"STMT_SELECT_NODE_CHILDREN", NULL}
+#define STMT_41 \
"SELECT DISTINCT local_relpath FROM nodes " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_WORKING_CHILDREN 41
-#define STMT_41_INFO {"STMT_SELECT_WORKING_CHILDREN", NULL}
-#define STMT_41 \
+#define STMT_SELECT_WORKING_CHILDREN 42
+#define STMT_42_INFO {"STMT_SELECT_WORKING_CHILDREN", NULL}
+#define STMT_42 \
"SELECT DISTINCT local_relpath FROM nodes " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
" AND (op_depth > (SELECT MAX(op_depth) FROM nodes " \
@@ -483,56 +497,56 @@
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_BASE_NOT_PRESENT_CHILDREN 42
-#define STMT_42_INFO {"STMT_SELECT_BASE_NOT_PRESENT_CHILDREN", NULL}
-#define STMT_42 \
+#define STMT_SELECT_BASE_NOT_PRESENT_CHILDREN 43
+#define STMT_43_INFO {"STMT_SELECT_BASE_NOT_PRESENT_CHILDREN", NULL}
+#define STMT_43 \
"SELECT local_relpath FROM nodes " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 AND op_depth = 0 " \
" AND presence = 'not-present' " \
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_NODE_PROPS 43
-#define STMT_43_INFO {"STMT_SELECT_NODE_PROPS", NULL}
-#define STMT_43 \
+#define STMT_SELECT_NODE_PROPS 44
+#define STMT_44_INFO {"STMT_SELECT_NODE_PROPS", NULL}
+#define STMT_44 \
"SELECT properties, presence FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
"ORDER BY op_depth DESC " \
""
-#define STMT_SELECT_ACTUAL_PROPS 44
-#define STMT_44_INFO {"STMT_SELECT_ACTUAL_PROPS", NULL}
-#define STMT_44 \
+#define STMT_SELECT_ACTUAL_PROPS 45
+#define STMT_45_INFO {"STMT_SELECT_ACTUAL_PROPS", NULL}
+#define STMT_45 \
"SELECT properties FROM actual_node " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_UPDATE_ACTUAL_PROPS 45
-#define STMT_45_INFO {"STMT_UPDATE_ACTUAL_PROPS", NULL}
-#define STMT_45 \
+#define STMT_UPDATE_ACTUAL_PROPS 46
+#define STMT_46_INFO {"STMT_UPDATE_ACTUAL_PROPS", NULL}
+#define STMT_46 \
"UPDATE actual_node SET properties = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_INSERT_ACTUAL_PROPS 46
-#define STMT_46_INFO {"STMT_INSERT_ACTUAL_PROPS", NULL}
-#define STMT_46 \
+#define STMT_INSERT_ACTUAL_PROPS 47
+#define STMT_47_INFO {"STMT_INSERT_ACTUAL_PROPS", NULL}
+#define STMT_47 \
"INSERT INTO actual_node (wc_id, local_relpath, parent_relpath, properties) " \
"VALUES (?1, ?2, ?3, ?4) " \
""
-#define STMT_INSERT_LOCK 47
-#define STMT_47_INFO {"STMT_INSERT_LOCK", NULL}
-#define STMT_47 \
+#define STMT_INSERT_LOCK 48
+#define STMT_48_INFO {"STMT_INSERT_LOCK", NULL}
+#define STMT_48 \
"INSERT OR REPLACE INTO lock " \
"(repos_id, repos_relpath, lock_token, lock_owner, lock_comment, " \
" lock_date) " \
"VALUES (?1, ?2, ?3, ?4, ?5, ?6) " \
""
-#define STMT_SELECT_BASE_NODE_LOCK_TOKENS_RECURSIVE 48
-#define STMT_48_INFO {"STMT_SELECT_BASE_NODE_LOCK_TOKENS_RECURSIVE", NULL}
-#define STMT_48 \
+#define STMT_SELECT_BASE_NODE_LOCK_TOKENS_RECURSIVE 49
+#define STMT_49_INFO {"STMT_SELECT_BASE_NODE_LOCK_TOKENS_RECURSIVE", NULL}
+#define STMT_49 \
"SELECT nodes.repos_id, nodes.repos_path, lock_token " \
"FROM nodes " \
"LEFT JOIN lock ON nodes.repos_id = lock.repos_id " \
@@ -541,30 +555,30 @@
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_INSERT_WCROOT 49
-#define STMT_49_INFO {"STMT_INSERT_WCROOT", NULL}
-#define STMT_49 \
+#define STMT_INSERT_WCROOT 50
+#define STMT_50_INFO {"STMT_INSERT_WCROOT", NULL}
+#define STMT_50 \
"INSERT INTO wcroot (local_abspath) " \
"VALUES (?1) " \
""
-#define STMT_UPDATE_BASE_NODE_DAV_CACHE 50
-#define STMT_50_INFO {"STMT_UPDATE_BASE_NODE_DAV_CACHE", NULL}
-#define STMT_50 \
+#define STMT_UPDATE_BASE_NODE_DAV_CACHE 51
+#define STMT_51_INFO {"STMT_UPDATE_BASE_NODE_DAV_CACHE", NULL}
+#define STMT_51 \
"UPDATE nodes SET dav_cache = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_SELECT_BASE_DAV_CACHE 51
-#define STMT_51_INFO {"STMT_SELECT_BASE_DAV_CACHE", NULL}
-#define STMT_51 \
+#define STMT_SELECT_BASE_DAV_CACHE 52
+#define STMT_52_INFO {"STMT_SELECT_BASE_DAV_CACHE", NULL}
+#define STMT_52 \
"SELECT dav_cache FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_SELECT_DELETION_INFO 52
-#define STMT_52_INFO {"STMT_SELECT_DELETION_INFO", NULL}
-#define STMT_52 \
+#define STMT_SELECT_DELETION_INFO 53
+#define STMT_53_INFO {"STMT_SELECT_DELETION_INFO", NULL}
+#define STMT_53 \
"SELECT b.presence, w.presence, w.op_depth, w.moved_to " \
"FROM nodes w " \
"LEFT JOIN nodes b ON b.wc_id = ?1 AND b.local_relpath = ?2 AND b.op_depth = 0 " \
@@ -575,18 +589,18 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_MOVED_TO_NODE 53
-#define STMT_53_INFO {"STMT_SELECT_MOVED_TO_NODE", NULL}
-#define STMT_53 \
+#define STMT_SELECT_MOVED_TO_NODE 54
+#define STMT_54_INFO {"STMT_SELECT_MOVED_TO_NODE", NULL}
+#define STMT_54 \
"SELECT op_depth, moved_to " \
"FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND moved_to IS NOT NULL " \
"ORDER BY op_depth DESC " \
""
-#define STMT_SELECT_OP_DEPTH_MOVED_TO 54
-#define STMT_54_INFO {"STMT_SELECT_OP_DEPTH_MOVED_TO", NULL}
-#define STMT_54 \
+#define STMT_SELECT_OP_DEPTH_MOVED_TO 55
+#define STMT_55_INFO {"STMT_SELECT_OP_DEPTH_MOVED_TO", NULL}
+#define STMT_55 \
"SELECT op_depth, moved_to " \
"FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth > ?3 " \
@@ -597,17 +611,17 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_MOVED_TO 55
-#define STMT_55_INFO {"STMT_SELECT_MOVED_TO", NULL}
-#define STMT_55 \
+#define STMT_SELECT_MOVED_TO 56
+#define STMT_56_INFO {"STMT_SELECT_MOVED_TO", NULL}
+#define STMT_56 \
"SELECT moved_to " \
"FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?3 " \
""
-#define STMT_SELECT_MOVED_BACK 56
-#define STMT_56_INFO {"STMT_SELECT_MOVED_BACK", NULL}
-#define STMT_56 \
+#define STMT_SELECT_MOVED_BACK 57
+#define STMT_57_INFO {"STMT_SELECT_MOVED_BACK", NULL}
+#define STMT_57 \
"SELECT u.local_relpath, " \
" u.presence, u.repos_id, u.repos_path, u.revision, " \
" l.presence, l.repos_id, l.repos_path, l.revision, " \
@@ -633,71 +647,71 @@
" AND u.op_depth = ?4 " \
""
-#define STMT_DELETE_LOCK 57
-#define STMT_57_INFO {"STMT_DELETE_LOCK", NULL}
-#define STMT_57 \
+#define STMT_DELETE_LOCK 58
+#define STMT_58_INFO {"STMT_DELETE_LOCK", NULL}
+#define STMT_58 \
"DELETE FROM lock " \
"WHERE repos_id = ?1 AND repos_relpath = ?2 " \
""
-#define STMT_DELETE_LOCK_RECURSIVELY 58
-#define STMT_58_INFO {"STMT_DELETE_LOCK_RECURSIVELY", NULL}
-#define STMT_58 \
+#define STMT_DELETE_LOCK_RECURSIVELY 59
+#define STMT_59_INFO {"STMT_DELETE_LOCK_RECURSIVELY", NULL}
+#define STMT_59 \
"DELETE FROM lock " \
"WHERE repos_id = ?1 AND (repos_relpath = ?2 OR (((repos_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((repos_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_CLEAR_BASE_NODE_RECURSIVE_DAV_CACHE 59
-#define STMT_59_INFO {"STMT_CLEAR_BASE_NODE_RECURSIVE_DAV_CACHE", NULL}
-#define STMT_59 \
+#define STMT_CLEAR_BASE_NODE_RECURSIVE_DAV_CACHE 60
+#define STMT_60_INFO {"STMT_CLEAR_BASE_NODE_RECURSIVE_DAV_CACHE", NULL}
+#define STMT_60 \
"UPDATE nodes SET dav_cache = NULL " \
"WHERE dav_cache IS NOT NULL AND wc_id = ?1 AND op_depth = 0 " \
" AND (local_relpath = ?2 " \
" OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_RECURSIVE_UPDATE_NODE_REPO 60
-#define STMT_60_INFO {"STMT_RECURSIVE_UPDATE_NODE_REPO", NULL}
-#define STMT_60 \
+#define STMT_RECURSIVE_UPDATE_NODE_REPO 61
+#define STMT_61_INFO {"STMT_RECURSIVE_UPDATE_NODE_REPO", NULL}
+#define STMT_61 \
"UPDATE nodes SET repos_id = ?4, dav_cache = NULL " \
"WHERE (wc_id = ?1 AND local_relpath = ?2 AND repos_id = ?3) " \
" OR (wc_id = ?1 AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND repos_id = ?3) " \
""
-#define STMT_UPDATE_LOCK_REPOS_ID 61
-#define STMT_61_INFO {"STMT_UPDATE_LOCK_REPOS_ID", NULL}
-#define STMT_61 \
+#define STMT_UPDATE_LOCK_REPOS_ID 62
+#define STMT_62_INFO {"STMT_UPDATE_LOCK_REPOS_ID", NULL}
+#define STMT_62 \
"UPDATE lock SET repos_id = ?2 " \
"WHERE repos_id = ?1 " \
""
-#define STMT_UPDATE_NODE_FILEINFO 62
-#define STMT_62_INFO {"STMT_UPDATE_NODE_FILEINFO", NULL}
-#define STMT_62 \
+#define STMT_UPDATE_NODE_FILEINFO 63
+#define STMT_63_INFO {"STMT_UPDATE_NODE_FILEINFO", NULL}
+#define STMT_63 \
"UPDATE nodes SET translated_size = ?3, last_mod_time = ?4 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
" AND op_depth = (SELECT MAX(op_depth) FROM nodes " \
" WHERE wc_id = ?1 AND local_relpath = ?2) " \
""
-#define STMT_INSERT_ACTUAL_CONFLICT 63
-#define STMT_63_INFO {"STMT_INSERT_ACTUAL_CONFLICT", NULL}
-#define STMT_63 \
+#define STMT_INSERT_ACTUAL_CONFLICT 64
+#define STMT_64_INFO {"STMT_INSERT_ACTUAL_CONFLICT", NULL}
+#define STMT_64 \
"INSERT INTO actual_node (wc_id, local_relpath, conflict_data, parent_relpath) " \
"VALUES (?1, ?2, ?3, ?4) " \
""
-#define STMT_UPDATE_ACTUAL_CONFLICT 64
-#define STMT_64_INFO {"STMT_UPDATE_ACTUAL_CONFLICT", NULL}
-#define STMT_64 \
+#define STMT_UPDATE_ACTUAL_CONFLICT 65
+#define STMT_65_INFO {"STMT_UPDATE_ACTUAL_CONFLICT", NULL}
+#define STMT_65 \
"UPDATE actual_node SET conflict_data = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_UPDATE_ACTUAL_CHANGELISTS 65
-#define STMT_65_INFO {"STMT_UPDATE_ACTUAL_CHANGELISTS", NULL}
-#define STMT_65 \
+#define STMT_UPDATE_ACTUAL_CHANGELISTS 66
+#define STMT_66_INFO {"STMT_UPDATE_ACTUAL_CHANGELISTS", NULL}
+#define STMT_66 \
"UPDATE actual_node SET changelist = ?3 " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
@@ -707,16 +721,16 @@
" AND kind = 'file') " \
""
-#define STMT_UPDATE_ACTUAL_CLEAR_CHANGELIST 66
-#define STMT_66_INFO {"STMT_UPDATE_ACTUAL_CLEAR_CHANGELIST", NULL}
-#define STMT_66 \
+#define STMT_UPDATE_ACTUAL_CLEAR_CHANGELIST 67
+#define STMT_67_INFO {"STMT_UPDATE_ACTUAL_CLEAR_CHANGELIST", NULL}
+#define STMT_67 \
"UPDATE actual_node SET changelist = NULL " \
" WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_MARK_SKIPPED_CHANGELIST_DIRS 67
-#define STMT_67_INFO {"STMT_MARK_SKIPPED_CHANGELIST_DIRS", NULL}
-#define STMT_67 \
+#define STMT_MARK_SKIPPED_CHANGELIST_DIRS 68
+#define STMT_68_INFO {"STMT_MARK_SKIPPED_CHANGELIST_DIRS", NULL}
+#define STMT_68 \
"INSERT INTO changelist_list (wc_id, local_relpath, notify, changelist) " \
"SELECT wc_id, local_relpath, 7, ?3 " \
"FROM targets_list " \
@@ -725,17 +739,17 @@
" AND kind = 'dir' " \
""
-#define STMT_RESET_ACTUAL_WITH_CHANGELIST 68
-#define STMT_68_INFO {"STMT_RESET_ACTUAL_WITH_CHANGELIST", NULL}
-#define STMT_68 \
+#define STMT_RESET_ACTUAL_WITH_CHANGELIST 69
+#define STMT_69_INFO {"STMT_RESET_ACTUAL_WITH_CHANGELIST", NULL}
+#define STMT_69 \
"REPLACE INTO actual_node ( " \
" wc_id, local_relpath, parent_relpath, changelist) " \
"VALUES (?1, ?2, ?3, ?4) " \
""
-#define STMT_CREATE_CHANGELIST_LIST 69
-#define STMT_69_INFO {"STMT_CREATE_CHANGELIST_LIST", NULL}
-#define STMT_69 \
+#define STMT_CREATE_CHANGELIST_LIST 70
+#define STMT_70_INFO {"STMT_CREATE_CHANGELIST_LIST", NULL}
+#define STMT_70 \
"DROP TABLE IF EXISTS changelist_list; " \
"CREATE TEMPORARY TABLE changelist_list ( " \
" wc_id INTEGER NOT NULL, " \
@@ -746,9 +760,9 @@
") " \
""
-#define STMT_CREATE_CHANGELIST_TRIGGER 70
-#define STMT_70_INFO {"STMT_CREATE_CHANGELIST_TRIGGER", NULL}
-#define STMT_70 \
+#define STMT_CREATE_CHANGELIST_TRIGGER 71
+#define STMT_71_INFO {"STMT_CREATE_CHANGELIST_TRIGGER", NULL}
+#define STMT_71 \
"DROP TRIGGER IF EXISTS trigger_changelist_list_change; " \
"CREATE TEMPORARY TRIGGER trigger_changelist_list_change " \
"BEFORE UPDATE ON actual_node " \
@@ -763,25 +777,25 @@
"END " \
""
-#define STMT_FINALIZE_CHANGELIST 71
-#define STMT_71_INFO {"STMT_FINALIZE_CHANGELIST", NULL}
-#define STMT_71 \
+#define STMT_FINALIZE_CHANGELIST 72
+#define STMT_72_INFO {"STMT_FINALIZE_CHANGELIST", NULL}
+#define STMT_72 \
"DROP TRIGGER trigger_changelist_list_change; " \
"DROP TABLE changelist_list; " \
"DROP TABLE targets_list " \
""
-#define STMT_SELECT_CHANGELIST_LIST 72
-#define STMT_72_INFO {"STMT_SELECT_CHANGELIST_LIST", NULL}
-#define STMT_72 \
+#define STMT_SELECT_CHANGELIST_LIST 73
+#define STMT_73_INFO {"STMT_SELECT_CHANGELIST_LIST", NULL}
+#define STMT_73 \
"SELECT wc_id, local_relpath, notify, changelist " \
"FROM changelist_list " \
"ORDER BY wc_id, local_relpath ASC, notify DESC " \
""
-#define STMT_CREATE_TARGETS_LIST 73
-#define STMT_73_INFO {"STMT_CREATE_TARGETS_LIST", NULL}
-#define STMT_73 \
+#define STMT_CREATE_TARGETS_LIST 74
+#define STMT_74_INFO {"STMT_CREATE_TARGETS_LIST", NULL}
+#define STMT_74 \
"DROP TABLE IF EXISTS targets_list; " \
"CREATE TEMPORARY TABLE targets_list ( " \
" wc_id INTEGER NOT NULL, " \
@@ -792,15 +806,15 @@
" ); " \
""
-#define STMT_DROP_TARGETS_LIST 74
-#define STMT_74_INFO {"STMT_DROP_TARGETS_LIST", NULL}
-#define STMT_74 \
+#define STMT_DROP_TARGETS_LIST 75
+#define STMT_75_INFO {"STMT_DROP_TARGETS_LIST", NULL}
+#define STMT_75 \
"DROP TABLE targets_list " \
""
-#define STMT_INSERT_TARGET 75
-#define STMT_75_INFO {"STMT_INSERT_TARGET", NULL}
-#define STMT_75 \
+#define STMT_INSERT_TARGET 76
+#define STMT_76_INFO {"STMT_INSERT_TARGET", NULL}
+#define STMT_76 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT wc_id, local_relpath, parent_relpath, kind " \
"FROM nodes_current " \
@@ -808,9 +822,9 @@
" AND local_relpath = ?2 " \
""
-#define STMT_INSERT_TARGET_DEPTH_FILES 76
-#define STMT_76_INFO {"STMT_INSERT_TARGET_DEPTH_FILES", NULL}
-#define STMT_76 \
+#define STMT_INSERT_TARGET_DEPTH_FILES 77
+#define STMT_77_INFO {"STMT_INSERT_TARGET_DEPTH_FILES", NULL}
+#define STMT_77 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT wc_id, local_relpath, parent_relpath, kind " \
"FROM nodes_current " \
@@ -819,9 +833,9 @@
" AND kind = 'file' " \
""
-#define STMT_INSERT_TARGET_DEPTH_IMMEDIATES 77
-#define STMT_77_INFO {"STMT_INSERT_TARGET_DEPTH_IMMEDIATES", NULL}
-#define STMT_77 \
+#define STMT_INSERT_TARGET_DEPTH_IMMEDIATES 78
+#define STMT_78_INFO {"STMT_INSERT_TARGET_DEPTH_IMMEDIATES", NULL}
+#define STMT_78 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT wc_id, local_relpath, parent_relpath, kind " \
"FROM nodes_current " \
@@ -829,9 +843,9 @@
" AND parent_relpath = ?2 " \
""
-#define STMT_INSERT_TARGET_DEPTH_INFINITY 78
-#define STMT_78_INFO {"STMT_INSERT_TARGET_DEPTH_INFINITY", NULL}
-#define STMT_78 \
+#define STMT_INSERT_TARGET_DEPTH_INFINITY 79
+#define STMT_79_INFO {"STMT_INSERT_TARGET_DEPTH_INFINITY", NULL}
+#define STMT_79 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT wc_id, local_relpath, parent_relpath, kind " \
"FROM nodes_current " \
@@ -839,9 +853,9 @@
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_INSERT_TARGET_WITH_CHANGELIST 79
-#define STMT_79_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST", NULL}
-#define STMT_79 \
+#define STMT_INSERT_TARGET_WITH_CHANGELIST 80
+#define STMT_80_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST", NULL}
+#define STMT_80 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT N.wc_id, N.local_relpath, N.parent_relpath, N.kind " \
" FROM actual_node AS A JOIN nodes_current AS N " \
@@ -851,9 +865,9 @@
" AND A.changelist = ?3 " \
""
-#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_FILES 80
-#define STMT_80_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_FILES", NULL}
-#define STMT_80 \
+#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_FILES 81
+#define STMT_81_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_FILES", NULL}
+#define STMT_81 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT N.wc_id, N.local_relpath, N.parent_relpath, N.kind " \
" FROM actual_node AS A JOIN nodes_current AS N " \
@@ -864,9 +878,9 @@
" AND A.changelist = ?3 " \
""
-#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_IMMEDIATES 81
-#define STMT_81_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_IMMEDIATES", NULL}
-#define STMT_81 \
+#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_IMMEDIATES 82
+#define STMT_82_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_IMMEDIATES", NULL}
+#define STMT_82 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT N.wc_id, N.local_relpath, N.parent_relpath, N.kind " \
" FROM actual_node AS A JOIN nodes_current AS N " \
@@ -876,9 +890,9 @@
" AND A.changelist = ?3 " \
""
-#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_INFINITY 82
-#define STMT_82_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_INFINITY", NULL}
-#define STMT_82 \
+#define STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_INFINITY 83
+#define STMT_83_INFO {"STMT_INSERT_TARGET_WITH_CHANGELIST_DEPTH_INFINITY", NULL}
+#define STMT_83 \
"INSERT INTO targets_list(wc_id, local_relpath, parent_relpath, kind) " \
"SELECT N.wc_id, N.local_relpath, N.parent_relpath, N.kind " \
" FROM actual_node AS A JOIN nodes_current AS N " \
@@ -888,18 +902,18 @@
" AND A.changelist = ?3 " \
""
-#define STMT_INSERT_ACTUAL_EMPTIES 83
-#define STMT_83_INFO {"STMT_INSERT_ACTUAL_EMPTIES", NULL}
-#define STMT_83 \
+#define STMT_INSERT_ACTUAL_EMPTIES 84
+#define STMT_84_INFO {"STMT_INSERT_ACTUAL_EMPTIES", NULL}
+#define STMT_84 \
"INSERT OR IGNORE INTO actual_node ( " \
" wc_id, local_relpath, parent_relpath) " \
"SELECT wc_id, local_relpath, parent_relpath " \
"FROM targets_list " \
""
-#define STMT_INSERT_ACTUAL_EMPTIES_FILES 84
-#define STMT_84_INFO {"STMT_INSERT_ACTUAL_EMPTIES_FILES", NULL}
-#define STMT_84 \
+#define STMT_INSERT_ACTUAL_EMPTIES_FILES 85
+#define STMT_85_INFO {"STMT_INSERT_ACTUAL_EMPTIES_FILES", NULL}
+#define STMT_85 \
"INSERT OR IGNORE INTO actual_node ( " \
" wc_id, local_relpath, parent_relpath) " \
"SELECT wc_id, local_relpath, parent_relpath " \
@@ -907,9 +921,9 @@
"WHERE kind='file' " \
""
-#define STMT_DELETE_ACTUAL_EMPTY 85
-#define STMT_85_INFO {"STMT_DELETE_ACTUAL_EMPTY", NULL}
-#define STMT_85 \
+#define STMT_DELETE_ACTUAL_EMPTY 86
+#define STMT_86_INFO {"STMT_DELETE_ACTUAL_EMPTY", NULL}
+#define STMT_86 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
" AND properties IS NULL " \
@@ -921,9 +935,9 @@
" AND left_checksum IS NULL " \
""
-#define STMT_DELETE_ACTUAL_EMPTIES 86
-#define STMT_86_INFO {"STMT_DELETE_ACTUAL_EMPTIES", NULL}
-#define STMT_86 \
+#define STMT_DELETE_ACTUAL_EMPTIES 87
+#define STMT_87_INFO {"STMT_DELETE_ACTUAL_EMPTIES", NULL}
+#define STMT_87 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
@@ -936,25 +950,25 @@
" AND left_checksum IS NULL " \
""
-#define STMT_DELETE_BASE_NODE 87
-#define STMT_87_INFO {"STMT_DELETE_BASE_NODE", NULL}
-#define STMT_87 \
+#define STMT_DELETE_BASE_NODE 88
+#define STMT_88_INFO {"STMT_DELETE_BASE_NODE", NULL}
+#define STMT_88 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_DELETE_WORKING_NODE 88
-#define STMT_88_INFO {"STMT_DELETE_WORKING_NODE", NULL}
-#define STMT_88 \
+#define STMT_DELETE_WORKING_NODE 89
+#define STMT_89_INFO {"STMT_DELETE_WORKING_NODE", NULL}
+#define STMT_89 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
" AND op_depth = (SELECT MAX(op_depth) FROM nodes " \
" WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth > 0) " \
""
-#define STMT_DELETE_LOWEST_WORKING_NODE 89
-#define STMT_89_INFO {"STMT_DELETE_LOWEST_WORKING_NODE", NULL}
-#define STMT_89 \
+#define STMT_DELETE_LOWEST_WORKING_NODE 90
+#define STMT_90_INFO {"STMT_DELETE_LOWEST_WORKING_NODE", NULL}
+#define STMT_90 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
" AND op_depth = (SELECT MIN(op_depth) FROM nodes " \
@@ -962,16 +976,16 @@
" AND presence = 'base-deleted' " \
""
-#define STMT_DELETE_NODE_ALL_LAYERS 90
-#define STMT_90_INFO {"STMT_DELETE_NODE_ALL_LAYERS", NULL}
-#define STMT_90 \
+#define STMT_DELETE_NODE_ALL_LAYERS 91
+#define STMT_91_INFO {"STMT_DELETE_NODE_ALL_LAYERS", NULL}
+#define STMT_91 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_DELETE_NODES_ABOVE_DEPTH_RECURSIVE 91
-#define STMT_91_INFO {"STMT_DELETE_NODES_ABOVE_DEPTH_RECURSIVE", NULL}
-#define STMT_91 \
+#define STMT_DELETE_NODES_ABOVE_DEPTH_RECURSIVE 92
+#define STMT_92_INFO {"STMT_DELETE_NODES_ABOVE_DEPTH_RECURSIVE", NULL}
+#define STMT_92 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
@@ -979,25 +993,25 @@
" AND op_depth >= ?3 " \
""
-#define STMT_DELETE_ACTUAL_NODE 92
-#define STMT_92_INFO {"STMT_DELETE_ACTUAL_NODE", NULL}
-#define STMT_92 \
+#define STMT_DELETE_ACTUAL_NODE 93
+#define STMT_93_INFO {"STMT_DELETE_ACTUAL_NODE", NULL}
+#define STMT_93 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_DELETE_ACTUAL_NODE_RECURSIVE 93
-#define STMT_93_INFO {"STMT_DELETE_ACTUAL_NODE_RECURSIVE", NULL}
-#define STMT_93 \
+#define STMT_DELETE_ACTUAL_NODE_RECURSIVE 94
+#define STMT_94_INFO {"STMT_DELETE_ACTUAL_NODE_RECURSIVE", NULL}
+#define STMT_94 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
" OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST 94
-#define STMT_94_INFO {"STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST", NULL}
-#define STMT_94 \
+#define STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST 95
+#define STMT_95_INFO {"STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST", NULL}
+#define STMT_95 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND local_relpath = ?2 " \
@@ -1007,9 +1021,9 @@
" AND c.kind = 'file')) " \
""
-#define STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE 95
-#define STMT_95_INFO {"STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE", NULL}
-#define STMT_95 \
+#define STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE 96
+#define STMT_96_INFO {"STMT_DELETE_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE", NULL}
+#define STMT_96 \
"DELETE FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
@@ -1021,9 +1035,9 @@
" AND c.kind = 'file')) " \
""
-#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST 96
-#define STMT_96_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST", NULL}
-#define STMT_96 \
+#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST 97
+#define STMT_97_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST", NULL}
+#define STMT_97 \
"UPDATE actual_node " \
"SET properties = NULL, " \
" text_mod = NULL, " \
@@ -1035,9 +1049,9 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CONFLICT 97
-#define STMT_97_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CONFLICT", NULL}
-#define STMT_97 \
+#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CONFLICT 98
+#define STMT_98_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CONFLICT", NULL}
+#define STMT_98 \
"UPDATE actual_node " \
"SET properties = NULL, " \
" text_mod = NULL, " \
@@ -1049,9 +1063,9 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE 98
-#define STMT_98_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE", NULL}
-#define STMT_98 \
+#define STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE 99
+#define STMT_99_INFO {"STMT_CLEAR_ACTUAL_NODE_LEAVING_CHANGELIST_RECURSIVE", NULL}
+#define STMT_99 \
"UPDATE actual_node " \
"SET properties = NULL, " \
" text_mod = NULL, " \
@@ -1065,109 +1079,109 @@
" OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_UPDATE_NODE_BASE_DEPTH 99
-#define STMT_99_INFO {"STMT_UPDATE_NODE_BASE_DEPTH", NULL}
-#define STMT_99 \
+#define STMT_UPDATE_NODE_BASE_DEPTH 100
+#define STMT_100_INFO {"STMT_UPDATE_NODE_BASE_DEPTH", NULL}
+#define STMT_100 \
"UPDATE nodes SET depth = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
" AND kind='dir' " \
" AND presence IN ('normal', 'incomplete') " \
""
-#define STMT_UPDATE_NODE_BASE_PRESENCE 100
-#define STMT_100_INFO {"STMT_UPDATE_NODE_BASE_PRESENCE", NULL}
-#define STMT_100 \
+#define STMT_UPDATE_NODE_BASE_PRESENCE 101
+#define STMT_101_INFO {"STMT_UPDATE_NODE_BASE_PRESENCE", NULL}
+#define STMT_101 \
"UPDATE nodes SET presence = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_UPDATE_BASE_NODE_PRESENCE_REVNUM_AND_REPOS_PATH 101
-#define STMT_101_INFO {"STMT_UPDATE_BASE_NODE_PRESENCE_REVNUM_AND_REPOS_PATH", NULL}
-#define STMT_101 \
+#define STMT_UPDATE_BASE_NODE_PRESENCE_REVNUM_AND_REPOS_PATH 102
+#define STMT_102_INFO {"STMT_UPDATE_BASE_NODE_PRESENCE_REVNUM_AND_REPOS_PATH", NULL}
+#define STMT_102 \
"UPDATE nodes SET presence = ?3, revision = ?4, repos_path = ?5 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_LOOK_FOR_WORK 102
-#define STMT_102_INFO {"STMT_LOOK_FOR_WORK", NULL}
-#define STMT_102 \
+#define STMT_LOOK_FOR_WORK 103
+#define STMT_103_INFO {"STMT_LOOK_FOR_WORK", NULL}
+#define STMT_103 \
"SELECT id FROM work_queue LIMIT 1 " \
""
-#define STMT_INSERT_WORK_ITEM 103
-#define STMT_103_INFO {"STMT_INSERT_WORK_ITEM", NULL}
-#define STMT_103 \
+#define STMT_INSERT_WORK_ITEM 104
+#define STMT_104_INFO {"STMT_INSERT_WORK_ITEM", NULL}
+#define STMT_104 \
"INSERT INTO work_queue (work) VALUES (?1) " \
""
-#define STMT_SELECT_WORK_ITEM 104
-#define STMT_104_INFO {"STMT_SELECT_WORK_ITEM", NULL}
-#define STMT_104 \
+#define STMT_SELECT_WORK_ITEM 105
+#define STMT_105_INFO {"STMT_SELECT_WORK_ITEM", NULL}
+#define STMT_105 \
"SELECT id, work FROM work_queue ORDER BY id LIMIT 1 " \
""
-#define STMT_DELETE_WORK_ITEM 105
-#define STMT_105_INFO {"STMT_DELETE_WORK_ITEM", NULL}
-#define STMT_105 \
+#define STMT_DELETE_WORK_ITEM 106
+#define STMT_106_INFO {"STMT_DELETE_WORK_ITEM", NULL}
+#define STMT_106 \
"DELETE FROM work_queue WHERE id = ?1 " \
""
-#define STMT_INSERT_OR_IGNORE_PRISTINE 106
-#define STMT_106_INFO {"STMT_INSERT_OR_IGNORE_PRISTINE", NULL}
-#define STMT_106 \
+#define STMT_INSERT_OR_IGNORE_PRISTINE 107
+#define STMT_107_INFO {"STMT_INSERT_OR_IGNORE_PRISTINE", NULL}
+#define STMT_107 \
"INSERT OR IGNORE INTO pristine (checksum, md5_checksum, size, refcount) " \
"VALUES (?1, ?2, ?3, 0) " \
""
-#define STMT_INSERT_PRISTINE 107
-#define STMT_107_INFO {"STMT_INSERT_PRISTINE", NULL}
-#define STMT_107 \
+#define STMT_INSERT_PRISTINE 108
+#define STMT_108_INFO {"STMT_INSERT_PRISTINE", NULL}
+#define STMT_108 \
"INSERT INTO pristine (checksum, md5_checksum, size, refcount) " \
"VALUES (?1, ?2, ?3, 0) " \
""
-#define STMT_SELECT_PRISTINE 108
-#define STMT_108_INFO {"STMT_SELECT_PRISTINE", NULL}
-#define STMT_108 \
+#define STMT_SELECT_PRISTINE 109
+#define STMT_109_INFO {"STMT_SELECT_PRISTINE", NULL}
+#define STMT_109 \
"SELECT md5_checksum " \
"FROM pristine " \
"WHERE checksum = ?1 " \
""
-#define STMT_SELECT_PRISTINE_SIZE 109
-#define STMT_109_INFO {"STMT_SELECT_PRISTINE_SIZE", NULL}
-#define STMT_109 \
+#define STMT_SELECT_PRISTINE_SIZE 110
+#define STMT_110_INFO {"STMT_SELECT_PRISTINE_SIZE", NULL}
+#define STMT_110 \
"SELECT size " \
"FROM pristine " \
"WHERE checksum = ?1 LIMIT 1 " \
""
-#define STMT_SELECT_PRISTINE_BY_MD5 110
-#define STMT_110_INFO {"STMT_SELECT_PRISTINE_BY_MD5", NULL}
-#define STMT_110 \
+#define STMT_SELECT_PRISTINE_BY_MD5 111
+#define STMT_111_INFO {"STMT_SELECT_PRISTINE_BY_MD5", NULL}
+#define STMT_111 \
"SELECT checksum " \
"FROM pristine " \
"WHERE md5_checksum = ?1 " \
""
-#define STMT_SELECT_UNREFERENCED_PRISTINES 111
-#define STMT_111_INFO {"STMT_SELECT_UNREFERENCED_PRISTINES", NULL}
-#define STMT_111 \
+#define STMT_SELECT_UNREFERENCED_PRISTINES 112
+#define STMT_112_INFO {"STMT_SELECT_UNREFERENCED_PRISTINES", NULL}
+#define STMT_112 \
"SELECT checksum " \
"FROM pristine " \
"WHERE refcount = 0 " \
""
-#define STMT_DELETE_PRISTINE_IF_UNREFERENCED 112
-#define STMT_112_INFO {"STMT_DELETE_PRISTINE_IF_UNREFERENCED", NULL}
-#define STMT_112 \
+#define STMT_DELETE_PRISTINE_IF_UNREFERENCED 113
+#define STMT_113_INFO {"STMT_DELETE_PRISTINE_IF_UNREFERENCED", NULL}
+#define STMT_113 \
"DELETE FROM pristine " \
"WHERE checksum = ?1 AND refcount = 0 " \
""
-#define STMT_SELECT_COPY_PRISTINES 113
-#define STMT_113_INFO {"STMT_SELECT_COPY_PRISTINES", NULL}
-#define STMT_113 \
+#define STMT_SELECT_COPY_PRISTINES 114
+#define STMT_114_INFO {"STMT_SELECT_COPY_PRISTINES", NULL}
+#define STMT_114 \
"SELECT n.checksum, md5_checksum, size " \
"FROM nodes_current n " \
"LEFT JOIN pristine p ON n.checksum = p.checksum " \
@@ -1185,62 +1199,62 @@
" AND n.checksum IS NOT NULL " \
""
-#define STMT_VACUUM 114
-#define STMT_114_INFO {"STMT_VACUUM", NULL}
-#define STMT_114 \
+#define STMT_VACUUM 115
+#define STMT_115_INFO {"STMT_VACUUM", NULL}
+#define STMT_115 \
"VACUUM " \
""
-#define STMT_SELECT_CONFLICT_VICTIMS 115
-#define STMT_115_INFO {"STMT_SELECT_CONFLICT_VICTIMS", NULL}
-#define STMT_115 \
+#define STMT_SELECT_CONFLICT_VICTIMS 116
+#define STMT_116_INFO {"STMT_SELECT_CONFLICT_VICTIMS", NULL}
+#define STMT_116 \
"SELECT local_relpath, conflict_data " \
"FROM actual_node " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 AND " \
" NOT (conflict_data IS NULL) " \
""
-#define STMT_INSERT_WC_LOCK 116
-#define STMT_116_INFO {"STMT_INSERT_WC_LOCK", NULL}
-#define STMT_116 \
+#define STMT_INSERT_WC_LOCK 117
+#define STMT_117_INFO {"STMT_INSERT_WC_LOCK", NULL}
+#define STMT_117 \
"INSERT INTO wc_lock (wc_id, local_dir_relpath, locked_levels) " \
"VALUES (?1, ?2, ?3) " \
""
-#define STMT_SELECT_WC_LOCK 117
-#define STMT_117_INFO {"STMT_SELECT_WC_LOCK", NULL}
-#define STMT_117 \
+#define STMT_SELECT_WC_LOCK 118
+#define STMT_118_INFO {"STMT_SELECT_WC_LOCK", NULL}
+#define STMT_118 \
"SELECT locked_levels FROM wc_lock " \
"WHERE wc_id = ?1 AND local_dir_relpath = ?2 " \
""
-#define STMT_SELECT_ANCESTOR_WCLOCKS 118
-#define STMT_118_INFO {"STMT_SELECT_ANCESTOR_WCLOCKS", NULL}
-#define STMT_118 \
+#define STMT_SELECT_ANCESTOR_WCLOCKS 119
+#define STMT_119_INFO {"STMT_SELECT_ANCESTOR_WCLOCKS", NULL}
+#define STMT_119 \
"SELECT local_dir_relpath, locked_levels FROM wc_lock " \
"WHERE wc_id = ?1 " \
" AND ((local_dir_relpath >= ?3 AND local_dir_relpath <= ?2) " \
" OR local_dir_relpath = '') " \
""
-#define STMT_DELETE_WC_LOCK 119
-#define STMT_119_INFO {"STMT_DELETE_WC_LOCK", NULL}
-#define STMT_119 \
+#define STMT_DELETE_WC_LOCK 120
+#define STMT_120_INFO {"STMT_DELETE_WC_LOCK", NULL}
+#define STMT_120 \
"DELETE FROM wc_lock " \
"WHERE wc_id = ?1 AND local_dir_relpath = ?2 " \
""
-#define STMT_FIND_WC_LOCK 120
-#define STMT_120_INFO {"STMT_FIND_WC_LOCK", NULL}
-#define STMT_120 \
+#define STMT_FIND_WC_LOCK 121
+#define STMT_121_INFO {"STMT_FIND_WC_LOCK", NULL}
+#define STMT_121 \
"SELECT local_dir_relpath FROM wc_lock " \
"WHERE wc_id = ?1 " \
" AND (((local_dir_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_dir_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_FIND_CONFLICT_DESCENDANT 121
-#define STMT_121_INFO {"STMT_FIND_CONFLICT_DESCENDANT", NULL}
-#define STMT_121 \
+#define STMT_FIND_CONFLICT_DESCENDANT 122
+#define STMT_122_INFO {"STMT_FIND_CONFLICT_DESCENDANT", NULL}
+#define STMT_122 \
"SELECT 1 FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND local_relpath > (?2 || '/') " \
@@ -1249,9 +1263,9 @@
"LIMIT 1 " \
""
-#define STMT_DELETE_WC_LOCK_ORPHAN 122
-#define STMT_122_INFO {"STMT_DELETE_WC_LOCK_ORPHAN", NULL}
-#define STMT_122 \
+#define STMT_DELETE_WC_LOCK_ORPHAN 123
+#define STMT_123_INFO {"STMT_DELETE_WC_LOCK_ORPHAN", NULL}
+#define STMT_123 \
"DELETE FROM wc_lock " \
"WHERE wc_id = ?1 AND local_dir_relpath = ?2 " \
"AND NOT EXISTS (SELECT 1 FROM nodes " \
@@ -1259,9 +1273,9 @@
" AND nodes.local_relpath = wc_lock.local_dir_relpath) " \
""
-#define STMT_DELETE_WC_LOCK_ORPHAN_RECURSIVE 123
-#define STMT_123_INFO {"STMT_DELETE_WC_LOCK_ORPHAN_RECURSIVE", NULL}
-#define STMT_123 \
+#define STMT_DELETE_WC_LOCK_ORPHAN_RECURSIVE 124
+#define STMT_124_INFO {"STMT_DELETE_WC_LOCK_ORPHAN_RECURSIVE", NULL}
+#define STMT_124 \
"DELETE FROM wc_lock " \
"WHERE wc_id = ?1 " \
" AND (local_dir_relpath = ?2 " \
@@ -1271,9 +1285,9 @@
" AND nodes.local_relpath = wc_lock.local_dir_relpath) " \
""
-#define STMT_APPLY_CHANGES_TO_BASE_NODE 124
-#define STMT_124_INFO {"STMT_APPLY_CHANGES_TO_BASE_NODE", NULL}
-#define STMT_124 \
+#define STMT_APPLY_CHANGES_TO_BASE_NODE 125
+#define STMT_125_INFO {"STMT_APPLY_CHANGES_TO_BASE_NODE", NULL}
+#define STMT_125 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, repos_path, " \
" revision, presence, depth, kind, changed_revision, changed_date, " \
@@ -1287,18 +1301,18 @@
" AND op_depth = 0)) " \
""
-#define STMT_INSTALL_WORKING_NODE_FOR_DELETE 125
-#define STMT_125_INFO {"STMT_INSTALL_WORKING_NODE_FOR_DELETE", NULL}
-#define STMT_125 \
+#define STMT_INSTALL_WORKING_NODE_FOR_DELETE 126
+#define STMT_126_INFO {"STMT_INSTALL_WORKING_NODE_FOR_DELETE", NULL}
+#define STMT_126 \
"INSERT INTO nodes ( " \
" wc_id, local_relpath, op_depth, " \
" parent_relpath, presence, kind) " \
"VALUES(?1, ?2, ?3, ?4, 'base-deleted', ?5) " \
""
-#define STMT_REPLACE_WITH_BASE_DELETED 126
-#define STMT_126_INFO {"STMT_REPLACE_WITH_BASE_DELETED", NULL}
-#define STMT_126 \
+#define STMT_REPLACE_WITH_BASE_DELETED 127
+#define STMT_127_INFO {"STMT_REPLACE_WITH_BASE_DELETED", NULL}
+#define STMT_127 \
"INSERT OR REPLACE INTO nodes (wc_id, local_relpath, op_depth, parent_relpath, " \
" kind, moved_to, presence) " \
"SELECT wc_id, local_relpath, op_depth, parent_relpath, " \
@@ -1309,9 +1323,9 @@
" AND op_depth = ?3 " \
""
-#define STMT_INSERT_DELETE_FROM_NODE_RECURSIVE 127
-#define STMT_127_INFO {"STMT_INSERT_DELETE_FROM_NODE_RECURSIVE", NULL}
-#define STMT_127 \
+#define STMT_INSERT_DELETE_FROM_NODE_RECURSIVE 128
+#define STMT_128_INFO {"STMT_INSERT_DELETE_FROM_NODE_RECURSIVE", NULL}
+#define STMT_128 \
"INSERT INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, presence, kind) " \
"SELECT wc_id, local_relpath, ?4 , parent_relpath, 'base-deleted', " \
@@ -1330,9 +1344,9 @@
"ORDER BY local_relpath " \
""
-#define STMT_INSERT_WORKING_NODE_FROM_BASE_COPY 128
-#define STMT_128_INFO {"STMT_INSERT_WORKING_NODE_FROM_BASE_COPY", NULL}
-#define STMT_128 \
+#define STMT_INSERT_WORKING_NODE_FROM_BASE_COPY 129
+#define STMT_129_INFO {"STMT_INSERT_WORKING_NODE_FROM_BASE_COPY", NULL}
+#define STMT_129 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, repos_path, " \
" revision, presence, depth, kind, changed_revision, changed_date, " \
@@ -1348,9 +1362,9 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_INSERT_DELETE_FROM_BASE 129
-#define STMT_129_INFO {"STMT_INSERT_DELETE_FROM_BASE", NULL}
-#define STMT_129 \
+#define STMT_INSERT_DELETE_FROM_BASE 130
+#define STMT_130_INFO {"STMT_INSERT_DELETE_FROM_BASE", NULL}
+#define STMT_130 \
"INSERT INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, presence, kind) " \
"SELECT wc_id, local_relpath, ?3 , parent_relpath, " \
@@ -1359,18 +1373,18 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_UPDATE_OP_DEPTH_INCREASE_RECURSIVE 130
-#define STMT_130_INFO {"STMT_UPDATE_OP_DEPTH_INCREASE_RECURSIVE", NULL}
-#define STMT_130 \
+#define STMT_UPDATE_OP_DEPTH_INCREASE_RECURSIVE 131
+#define STMT_131_INFO {"STMT_UPDATE_OP_DEPTH_INCREASE_RECURSIVE", NULL}
+#define STMT_131 \
"UPDATE nodes SET op_depth = ?3 + 1 " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND op_depth = ?3 " \
""
-#define STMT_COPY_OP_DEPTH_RECURSIVE 131
-#define STMT_131_INFO {"STMT_COPY_OP_DEPTH_RECURSIVE", NULL}
-#define STMT_131 \
+#define STMT_COPY_OP_DEPTH_RECURSIVE 132
+#define STMT_132_INFO {"STMT_COPY_OP_DEPTH_RECURSIVE", NULL}
+#define STMT_132 \
"INSERT INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, repos_path, " \
" revision, presence, depth, kind, changed_revision, changed_date, " \
@@ -1395,16 +1409,16 @@
"ORDER BY local_relpath " \
""
-#define STMT_DOES_NODE_EXIST 132
-#define STMT_132_INFO {"STMT_DOES_NODE_EXIST", NULL}
-#define STMT_132 \
+#define STMT_DOES_NODE_EXIST 133
+#define STMT_133_INFO {"STMT_DOES_NODE_EXIST", NULL}
+#define STMT_133 \
"SELECT 1 FROM nodes WHERE wc_id = ?1 AND local_relpath = ?2 " \
"LIMIT 1 " \
""
-#define STMT_HAS_SERVER_EXCLUDED_DESCENDANTS 133
-#define STMT_133_INFO {"STMT_HAS_SERVER_EXCLUDED_DESCENDANTS", NULL}
-#define STMT_133 \
+#define STMT_HAS_SERVER_EXCLUDED_DESCENDANTS 134
+#define STMT_134_INFO {"STMT_HAS_SERVER_EXCLUDED_DESCENDANTS", NULL}
+#define STMT_134 \
"SELECT local_relpath FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -1412,9 +1426,9 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_ALL_EXCLUDED_DESCENDANTS 134
-#define STMT_134_INFO {"STMT_SELECT_ALL_EXCLUDED_DESCENDANTS", NULL}
-#define STMT_134 \
+#define STMT_SELECT_ALL_EXCLUDED_DESCENDANTS 135
+#define STMT_135_INFO {"STMT_SELECT_ALL_EXCLUDED_DESCENDANTS", NULL}
+#define STMT_135 \
"SELECT local_relpath FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -1422,9 +1436,9 @@
" AND (presence = 'server-excluded' OR presence = 'excluded') " \
""
-#define STMT_INSERT_WORKING_NODE_COPY_FROM 135
-#define STMT_135_INFO {"STMT_INSERT_WORKING_NODE_COPY_FROM", NULL}
-#define STMT_135 \
+#define STMT_INSERT_WORKING_NODE_COPY_FROM 136
+#define STMT_136_INFO {"STMT_INSERT_WORKING_NODE_COPY_FROM", NULL}
+#define STMT_136 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, " \
" repos_path, revision, presence, depth, moved_here, kind, changed_revision, " \
@@ -1443,9 +1457,9 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_INSERT_WORKING_NODE_COPY_FROM_DEPTH 136
-#define STMT_136_INFO {"STMT_INSERT_WORKING_NODE_COPY_FROM_DEPTH", NULL}
-#define STMT_136 \
+#define STMT_INSERT_WORKING_NODE_COPY_FROM_DEPTH 137
+#define STMT_137_INFO {"STMT_INSERT_WORKING_NODE_COPY_FROM_DEPTH", NULL}
+#define STMT_137 \
"INSERT OR REPLACE INTO nodes ( " \
" wc_id, local_relpath, op_depth, parent_relpath, repos_id, " \
" repos_path, revision, presence, depth, moved_here, kind, changed_revision, " \
@@ -1464,49 +1478,49 @@
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?7 " \
""
-#define STMT_UPDATE_BASE_REVISION 137
-#define STMT_137_INFO {"STMT_UPDATE_BASE_REVISION", NULL}
-#define STMT_137 \
+#define STMT_UPDATE_BASE_REVISION 138
+#define STMT_138_INFO {"STMT_UPDATE_BASE_REVISION", NULL}
+#define STMT_138 \
"UPDATE nodes SET revision = ?3 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_UPDATE_BASE_REPOS 138
-#define STMT_138_INFO {"STMT_UPDATE_BASE_REPOS", NULL}
-#define STMT_138 \
+#define STMT_UPDATE_BASE_REPOS 139
+#define STMT_139_INFO {"STMT_UPDATE_BASE_REPOS", NULL}
+#define STMT_139 \
"UPDATE nodes SET repos_id = ?3, repos_path = ?4 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0 " \
""
-#define STMT_ACTUAL_HAS_CHILDREN 139
-#define STMT_139_INFO {"STMT_ACTUAL_HAS_CHILDREN", NULL}
-#define STMT_139 \
+#define STMT_ACTUAL_HAS_CHILDREN 140
+#define STMT_140_INFO {"STMT_ACTUAL_HAS_CHILDREN", NULL}
+#define STMT_140 \
"SELECT 1 FROM actual_node " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 " \
"LIMIT 1 " \
""
-#define STMT_INSERT_EXTERNAL 140
-#define STMT_140_INFO {"STMT_INSERT_EXTERNAL", NULL}
-#define STMT_140 \
+#define STMT_INSERT_EXTERNAL 141
+#define STMT_141_INFO {"STMT_INSERT_EXTERNAL", NULL}
+#define STMT_141 \
"INSERT OR REPLACE INTO externals ( " \
" wc_id, local_relpath, parent_relpath, presence, kind, def_local_relpath, " \
" repos_id, def_repos_relpath, def_operational_revision, def_revision) " \
"VALUES (?1, ?2, ?3, ?4, ?5, ?6, ?7, ?8, ?9, ?10) " \
""
-#define STMT_SELECT_EXTERNAL_INFO 141
-#define STMT_141_INFO {"STMT_SELECT_EXTERNAL_INFO", NULL}
-#define STMT_141 \
+#define STMT_SELECT_EXTERNAL_INFO 142
+#define STMT_142_INFO {"STMT_SELECT_EXTERNAL_INFO", NULL}
+#define STMT_142 \
"SELECT presence, kind, def_local_relpath, repos_id, " \
" def_repos_relpath, def_operational_revision, def_revision " \
"FROM externals WHERE wc_id = ?1 AND local_relpath = ?2 " \
"LIMIT 1 " \
""
-#define STMT_DELETE_FILE_EXTERNALS 142
-#define STMT_142_INFO {"STMT_DELETE_FILE_EXTERNALS", NULL}
-#define STMT_142 \
+#define STMT_DELETE_FILE_EXTERNALS 143
+#define STMT_143_INFO {"STMT_DELETE_FILE_EXTERNALS", NULL}
+#define STMT_143 \
"DELETE FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -1514,26 +1528,26 @@
" AND file_external IS NOT NULL " \
""
-#define STMT_DELETE_FILE_EXTERNAL_REGISTATIONS 143
-#define STMT_143_INFO {"STMT_DELETE_FILE_EXTERNAL_REGISTATIONS", NULL}
-#define STMT_143 \
+#define STMT_DELETE_FILE_EXTERNAL_REGISTATIONS 144
+#define STMT_144_INFO {"STMT_DELETE_FILE_EXTERNAL_REGISTATIONS", NULL}
+#define STMT_144 \
"DELETE FROM externals " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
" AND kind != 'dir' " \
""
-#define STMT_DELETE_EXTERNAL_REGISTATIONS 144
-#define STMT_144_INFO {"STMT_DELETE_EXTERNAL_REGISTATIONS", NULL}
-#define STMT_144 \
+#define STMT_DELETE_EXTERNAL_REGISTATIONS 145
+#define STMT_145_INFO {"STMT_DELETE_EXTERNAL_REGISTATIONS", NULL}
+#define STMT_145 \
"DELETE FROM externals " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_SELECT_COMMITTABLE_EXTERNALS_BELOW 145
-#define STMT_145_INFO {"STMT_SELECT_COMMITTABLE_EXTERNALS_BELOW", NULL}
-#define STMT_145 \
+#define STMT_SELECT_COMMITTABLE_EXTERNALS_BELOW 146
+#define STMT_146_INFO {"STMT_SELECT_COMMITTABLE_EXTERNALS_BELOW", NULL}
+#define STMT_146 \
"SELECT local_relpath, kind, def_repos_relpath, " \
" (SELECT root FROM repository AS r WHERE r.id = e.repos_id) " \
"FROM externals e " \
@@ -1551,9 +1565,9 @@
" AND nodes.local_relpath = e.parent_relpath)) " \
""
-#define STMT_SELECT_COMMITTABLE_EXTERNALS_IMMEDIATELY_BELOW 146
-#define STMT_146_INFO {"STMT_SELECT_COMMITTABLE_EXTERNALS_IMMEDIATELY_BELOW", NULL}
-#define STMT_146 \
+#define STMT_SELECT_COMMITTABLE_EXTERNALS_IMMEDIATELY_BELOW 147
+#define STMT_147_INFO {"STMT_SELECT_COMMITTABLE_EXTERNALS_IMMEDIATELY_BELOW", NULL}
+#define STMT_147 \
"SELECT local_relpath, kind, def_repos_relpath, " \
" (SELECT root FROM repository AS r WHERE r.id = e.repos_id) " \
"FROM externals e " \
@@ -1572,25 +1586,25 @@
" AND nodes.local_relpath = e.parent_relpath)) " \
""
-#define STMT_SELECT_EXTERNALS_DEFINED 147
-#define STMT_147_INFO {"STMT_SELECT_EXTERNALS_DEFINED", NULL}
-#define STMT_147 \
+#define STMT_SELECT_EXTERNALS_DEFINED 148
+#define STMT_148_INFO {"STMT_SELECT_EXTERNALS_DEFINED", NULL}
+#define STMT_148 \
"SELECT local_relpath, def_local_relpath " \
"FROM externals " \
"WHERE (wc_id = ?1 AND def_local_relpath = ?2) " \
" OR (wc_id = ?1 AND (((def_local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((def_local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_DELETE_EXTERNAL 148
-#define STMT_148_INFO {"STMT_DELETE_EXTERNAL", NULL}
-#define STMT_148 \
+#define STMT_DELETE_EXTERNAL 149
+#define STMT_149_INFO {"STMT_DELETE_EXTERNAL", NULL}
+#define STMT_149 \
"DELETE FROM externals " \
"WHERE wc_id = ?1 AND local_relpath = ?2 " \
""
-#define STMT_SELECT_EXTERNAL_PROPERTIES 149
-#define STMT_149_INFO {"STMT_SELECT_EXTERNAL_PROPERTIES", NULL}
-#define STMT_149 \
+#define STMT_SELECT_EXTERNAL_PROPERTIES 150
+#define STMT_150_INFO {"STMT_SELECT_EXTERNAL_PROPERTIES", NULL}
+#define STMT_150 \
"SELECT IFNULL((SELECT properties FROM actual_node a " \
" WHERE a.wc_id = ?1 AND A.local_relpath = n.local_relpath), " \
" properties), " \
@@ -1608,9 +1622,9 @@
" AND kind = 'dir' AND presence IN ('normal', 'incomplete') " \
""
-#define STMT_SELECT_CURRENT_PROPS_RECURSIVE 150
-#define STMT_150_INFO {"STMT_SELECT_CURRENT_PROPS_RECURSIVE", NULL}
-#define STMT_150 \
+#define STMT_SELECT_CURRENT_PROPS_RECURSIVE 151
+#define STMT_151_INFO {"STMT_SELECT_CURRENT_PROPS_RECURSIVE", NULL}
+#define STMT_151 \
"SELECT IFNULL((SELECT properties FROM actual_node a " \
" WHERE a.wc_id = ?1 AND A.local_relpath = n.local_relpath), " \
" properties), " \
@@ -1620,51 +1634,51 @@
" OR (wc_id = ?1 AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
""
-#define STMT_PRAGMA_LOCKING_MODE 151
-#define STMT_151_INFO {"STMT_PRAGMA_LOCKING_MODE", NULL}
-#define STMT_151 \
+#define STMT_PRAGMA_LOCKING_MODE 152
+#define STMT_152_INFO {"STMT_PRAGMA_LOCKING_MODE", NULL}
+#define STMT_152 \
"PRAGMA locking_mode = exclusive; " \
"PRAGMA journal_mode = DELETE " \
""
-#define STMT_FIND_REPOS_PATH_IN_WC 152
-#define STMT_152_INFO {"STMT_FIND_REPOS_PATH_IN_WC", NULL}
-#define STMT_152 \
+#define STMT_FIND_REPOS_PATH_IN_WC 153
+#define STMT_153_INFO {"STMT_FIND_REPOS_PATH_IN_WC", NULL}
+#define STMT_153 \
"SELECT local_relpath FROM nodes_current " \
" WHERE wc_id = ?1 AND repos_path = ?2 " \
""
-#define STMT_INSERT_ACTUAL_NODE 153
-#define STMT_153_INFO {"STMT_INSERT_ACTUAL_NODE", NULL}
-#define STMT_153 \
+#define STMT_INSERT_ACTUAL_NODE 154
+#define STMT_154_INFO {"STMT_INSERT_ACTUAL_NODE", NULL}
+#define STMT_154 \
"INSERT OR REPLACE INTO actual_node ( " \
" wc_id, local_relpath, parent_relpath, properties, changelist, conflict_data) " \
"VALUES (?1, ?2, ?3, ?4, ?5, ?6) " \
""
-#define STMT_SELECT_ALL_FILES 154
-#define STMT_154_INFO {"STMT_SELECT_ALL_FILES", NULL}
-#define STMT_154 \
+#define STMT_SELECT_ALL_FILES 155
+#define STMT_155_INFO {"STMT_SELECT_ALL_FILES", NULL}
+#define STMT_155 \
"SELECT local_relpath FROM nodes_current " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 AND kind = 'file' " \
""
-#define STMT_UPDATE_NODE_PROPS 155
-#define STMT_155_INFO {"STMT_UPDATE_NODE_PROPS", NULL}
-#define STMT_155 \
+#define STMT_UPDATE_NODE_PROPS 156
+#define STMT_156_INFO {"STMT_UPDATE_NODE_PROPS", NULL}
+#define STMT_156 \
"UPDATE nodes SET properties = ?4 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?3 " \
""
-#define STMT_PRAGMA_TABLE_INFO_NODES 156
-#define STMT_156_INFO {"STMT_PRAGMA_TABLE_INFO_NODES", NULL}
-#define STMT_156 \
+#define STMT_PRAGMA_TABLE_INFO_NODES 157
+#define STMT_157_INFO {"STMT_PRAGMA_TABLE_INFO_NODES", NULL}
+#define STMT_157 \
"PRAGMA table_info(\"NODES\") " \
""
-#define STMT_CREATE_TARGET_PROP_CACHE 157
-#define STMT_157_INFO {"STMT_CREATE_TARGET_PROP_CACHE", NULL}
-#define STMT_157 \
+#define STMT_CREATE_TARGET_PROP_CACHE 158
+#define STMT_158_INFO {"STMT_CREATE_TARGET_PROP_CACHE", NULL}
+#define STMT_158 \
"DROP TABLE IF EXISTS target_prop_cache; " \
"CREATE TEMPORARY TABLE target_prop_cache ( " \
" local_relpath TEXT NOT NULL PRIMARY KEY, " \
@@ -1673,9 +1687,9 @@
"); " \
""
-#define STMT_CACHE_TARGET_PROPS 158
-#define STMT_158_INFO {"STMT_CACHE_TARGET_PROPS", NULL}
-#define STMT_158 \
+#define STMT_CACHE_TARGET_PROPS 159
+#define STMT_159_INFO {"STMT_CACHE_TARGET_PROPS", NULL}
+#define STMT_159 \
"INSERT INTO target_prop_cache(local_relpath, kind, properties) " \
" SELECT n.local_relpath, n.kind, " \
" IFNULL((SELECT properties FROM actual_node AS a " \
@@ -1694,9 +1708,9 @@
" ORDER BY t.local_relpath " \
""
-#define STMT_CACHE_TARGET_PRISTINE_PROPS 159
-#define STMT_159_INFO {"STMT_CACHE_TARGET_PRISTINE_PROPS", NULL}
-#define STMT_159 \
+#define STMT_CACHE_TARGET_PRISTINE_PROPS 160
+#define STMT_160_INFO {"STMT_CACHE_TARGET_PRISTINE_PROPS", NULL}
+#define STMT_160 \
"INSERT INTO target_prop_cache(local_relpath, kind, properties) " \
" SELECT n.local_relpath, n.kind, " \
" CASE n.presence " \
@@ -1721,22 +1735,22 @@
" ORDER BY t.local_relpath " \
""
-#define STMT_SELECT_ALL_TARGET_PROP_CACHE 160
-#define STMT_160_INFO {"STMT_SELECT_ALL_TARGET_PROP_CACHE", NULL}
-#define STMT_160 \
+#define STMT_SELECT_ALL_TARGET_PROP_CACHE 161
+#define STMT_161_INFO {"STMT_SELECT_ALL_TARGET_PROP_CACHE", NULL}
+#define STMT_161 \
"SELECT local_relpath, properties FROM target_prop_cache " \
"ORDER BY local_relpath " \
""
-#define STMT_DROP_TARGET_PROP_CACHE 161
-#define STMT_161_INFO {"STMT_DROP_TARGET_PROP_CACHE", NULL}
-#define STMT_161 \
+#define STMT_DROP_TARGET_PROP_CACHE 162
+#define STMT_162_INFO {"STMT_DROP_TARGET_PROP_CACHE", NULL}
+#define STMT_162 \
"DROP TABLE target_prop_cache; " \
""
-#define STMT_CREATE_REVERT_LIST 162
-#define STMT_162_INFO {"STMT_CREATE_REVERT_LIST", NULL}
-#define STMT_162 \
+#define STMT_CREATE_REVERT_LIST 163
+#define STMT_163_INFO {"STMT_CREATE_REVERT_LIST", NULL}
+#define STMT_163 \
"DROP TABLE IF EXISTS revert_list; " \
"CREATE TEMPORARY TABLE revert_list ( " \
" local_relpath TEXT NOT NULL, " \
@@ -1794,26 +1808,26 @@
"END " \
""
-#define STMT_DROP_REVERT_LIST_TRIGGERS 163
-#define STMT_163_INFO {"STMT_DROP_REVERT_LIST_TRIGGERS", NULL}
-#define STMT_163 \
+#define STMT_DROP_REVERT_LIST_TRIGGERS 164
+#define STMT_164_INFO {"STMT_DROP_REVERT_LIST_TRIGGERS", NULL}
+#define STMT_164 \
"DROP TRIGGER trigger_revert_list_nodes; " \
"DROP TRIGGER trigger_revert_list_actual_delete; " \
"DROP TRIGGER trigger_revert_list_actual_update " \
""
-#define STMT_SELECT_REVERT_LIST 164
-#define STMT_164_INFO {"STMT_SELECT_REVERT_LIST", NULL}
-#define STMT_164 \
+#define STMT_SELECT_REVERT_LIST 165
+#define STMT_165_INFO {"STMT_SELECT_REVERT_LIST", NULL}
+#define STMT_165 \
"SELECT actual, notify, kind, op_depth, repos_id, conflict_data " \
"FROM revert_list " \
"WHERE local_relpath = ?1 " \
"ORDER BY actual DESC " \
""
-#define STMT_SELECT_REVERT_LIST_COPIED_CHILDREN 165
-#define STMT_165_INFO {"STMT_SELECT_REVERT_LIST_COPIED_CHILDREN", NULL}
-#define STMT_165 \
+#define STMT_SELECT_REVERT_LIST_COPIED_CHILDREN 166
+#define STMT_166_INFO {"STMT_SELECT_REVERT_LIST_COPIED_CHILDREN", NULL}
+#define STMT_166 \
"SELECT local_relpath, kind " \
"FROM revert_list " \
"WHERE (((local_relpath) > (CASE (?1) WHEN '' THEN '' ELSE (?1) || '/' END)) AND ((local_relpath) < CASE (?1) WHEN '' THEN X'FFFF' ELSE (?1) || '0' END)) " \
@@ -1822,15 +1836,15 @@
"ORDER BY local_relpath " \
""
-#define STMT_DELETE_REVERT_LIST 166
-#define STMT_166_INFO {"STMT_DELETE_REVERT_LIST", NULL}
-#define STMT_166 \
+#define STMT_DELETE_REVERT_LIST 167
+#define STMT_167_INFO {"STMT_DELETE_REVERT_LIST", NULL}
+#define STMT_167 \
"DELETE FROM revert_list WHERE local_relpath = ?1 " \
""
-#define STMT_SELECT_REVERT_LIST_RECURSIVE 167
-#define STMT_167_INFO {"STMT_SELECT_REVERT_LIST_RECURSIVE", NULL}
-#define STMT_167 \
+#define STMT_SELECT_REVERT_LIST_RECURSIVE 168
+#define STMT_168_INFO {"STMT_SELECT_REVERT_LIST_RECURSIVE", NULL}
+#define STMT_168 \
"SELECT p.local_relpath, n.kind, a.notify, a.kind " \
"FROM (SELECT DISTINCT local_relpath " \
" FROM revert_list " \
@@ -1841,32 +1855,32 @@
"ORDER BY p.local_relpath " \
""
-#define STMT_DELETE_REVERT_LIST_RECURSIVE 168
-#define STMT_168_INFO {"STMT_DELETE_REVERT_LIST_RECURSIVE", NULL}
-#define STMT_168 \
+#define STMT_DELETE_REVERT_LIST_RECURSIVE 169
+#define STMT_169_INFO {"STMT_DELETE_REVERT_LIST_RECURSIVE", NULL}
+#define STMT_169 \
"DELETE FROM revert_list " \
"WHERE (local_relpath = ?1 " \
" OR (((local_relpath) > (CASE (?1) WHEN '' THEN '' ELSE (?1) || '/' END)) AND ((local_relpath) < CASE (?1) WHEN '' THEN X'FFFF' ELSE (?1) || '0' END))) " \
""
-#define STMT_DROP_REVERT_LIST 169
-#define STMT_169_INFO {"STMT_DROP_REVERT_LIST", NULL}
-#define STMT_169 \
+#define STMT_DROP_REVERT_LIST 170
+#define STMT_170_INFO {"STMT_DROP_REVERT_LIST", NULL}
+#define STMT_170 \
"DROP TABLE IF EXISTS revert_list " \
""
-#define STMT_CREATE_DELETE_LIST 170
-#define STMT_170_INFO {"STMT_CREATE_DELETE_LIST", NULL}
-#define STMT_170 \
+#define STMT_CREATE_DELETE_LIST 171
+#define STMT_171_INFO {"STMT_CREATE_DELETE_LIST", NULL}
+#define STMT_171 \
"DROP TABLE IF EXISTS delete_list; " \
"CREATE TEMPORARY TABLE delete_list ( " \
" local_relpath TEXT PRIMARY KEY NOT NULL UNIQUE " \
" ) " \
""
-#define STMT_INSERT_DELETE_LIST 171
-#define STMT_171_INFO {"STMT_INSERT_DELETE_LIST", NULL}
-#define STMT_171 \
+#define STMT_INSERT_DELETE_LIST 172
+#define STMT_172_INFO {"STMT_INSERT_DELETE_LIST", NULL}
+#define STMT_172 \
"INSERT INTO delete_list(local_relpath) " \
"SELECT ?2 " \
"UNION ALL " \
@@ -1882,22 +1896,22 @@
"ORDER by local_relpath " \
""
-#define STMT_SELECT_DELETE_LIST 172
-#define STMT_172_INFO {"STMT_SELECT_DELETE_LIST", NULL}
-#define STMT_172 \
+#define STMT_SELECT_DELETE_LIST 173
+#define STMT_173_INFO {"STMT_SELECT_DELETE_LIST", NULL}
+#define STMT_173 \
"SELECT local_relpath FROM delete_list " \
"ORDER BY local_relpath " \
""
-#define STMT_FINALIZE_DELETE 173
-#define STMT_173_INFO {"STMT_FINALIZE_DELETE", NULL}
-#define STMT_173 \
+#define STMT_FINALIZE_DELETE 174
+#define STMT_174_INFO {"STMT_FINALIZE_DELETE", NULL}
+#define STMT_174 \
"DROP TABLE IF EXISTS delete_list " \
""
-#define STMT_CREATE_UPDATE_MOVE_LIST 174
-#define STMT_174_INFO {"STMT_CREATE_UPDATE_MOVE_LIST", NULL}
-#define STMT_174 \
+#define STMT_CREATE_UPDATE_MOVE_LIST 175
+#define STMT_175_INFO {"STMT_CREATE_UPDATE_MOVE_LIST", NULL}
+#define STMT_175 \
"DROP TABLE IF EXISTS update_move_list; " \
"CREATE TEMPORARY TABLE update_move_list ( " \
" local_relpath TEXT PRIMARY KEY NOT NULL UNIQUE, " \
@@ -1908,39 +1922,39 @@
" ) " \
""
-#define STMT_INSERT_UPDATE_MOVE_LIST 175
-#define STMT_175_INFO {"STMT_INSERT_UPDATE_MOVE_LIST", NULL}
-#define STMT_175 \
+#define STMT_INSERT_UPDATE_MOVE_LIST 176
+#define STMT_176_INFO {"STMT_INSERT_UPDATE_MOVE_LIST", NULL}
+#define STMT_176 \
"INSERT INTO update_move_list(local_relpath, action, kind, content_state, " \
" prop_state) " \
"VALUES (?1, ?2, ?3, ?4, ?5) " \
""
-#define STMT_SELECT_UPDATE_MOVE_LIST 176
-#define STMT_176_INFO {"STMT_SELECT_UPDATE_MOVE_LIST", NULL}
-#define STMT_176 \
+#define STMT_SELECT_UPDATE_MOVE_LIST 177
+#define STMT_177_INFO {"STMT_SELECT_UPDATE_MOVE_LIST", NULL}
+#define STMT_177 \
"SELECT local_relpath, action, kind, content_state, prop_state " \
"FROM update_move_list " \
"ORDER BY local_relpath " \
""
-#define STMT_FINALIZE_UPDATE_MOVE 177
-#define STMT_177_INFO {"STMT_FINALIZE_UPDATE_MOVE", NULL}
-#define STMT_177 \
+#define STMT_FINALIZE_UPDATE_MOVE 178
+#define STMT_178_INFO {"STMT_FINALIZE_UPDATE_MOVE", NULL}
+#define STMT_178 \
"DROP TABLE IF EXISTS update_move_list " \
""
-#define STMT_MOVE_NOTIFY_TO_REVERT 178
-#define STMT_178_INFO {"STMT_MOVE_NOTIFY_TO_REVERT", NULL}
-#define STMT_178 \
+#define STMT_MOVE_NOTIFY_TO_REVERT 179
+#define STMT_179_INFO {"STMT_MOVE_NOTIFY_TO_REVERT", NULL}
+#define STMT_179 \
"INSERT INTO revert_list (local_relpath, notify, kind, actual) " \
" SELECT local_relpath, 2, kind, 1 FROM update_move_list; " \
"DROP TABLE update_move_list " \
""
-#define STMT_SELECT_MIN_MAX_REVISIONS 179
-#define STMT_179_INFO {"STMT_SELECT_MIN_MAX_REVISIONS", NULL}
-#define STMT_179 \
+#define STMT_SELECT_MIN_MAX_REVISIONS 180
+#define STMT_180_INFO {"STMT_SELECT_MIN_MAX_REVISIONS", NULL}
+#define STMT_180 \
"SELECT MIN(revision), MAX(revision), " \
" MIN(changed_revision), MAX(changed_revision) FROM nodes " \
" WHERE wc_id = ?1 " \
@@ -1951,9 +1965,9 @@
" AND op_depth = 0 " \
""
-#define STMT_HAS_SPARSE_NODES 180
-#define STMT_180_INFO {"STMT_HAS_SPARSE_NODES", NULL}
-#define STMT_180 \
+#define STMT_HAS_SPARSE_NODES 181
+#define STMT_181_INFO {"STMT_HAS_SPARSE_NODES", NULL}
+#define STMT_181 \
"SELECT 1 FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
@@ -1965,9 +1979,9 @@
"LIMIT 1 " \
""
-#define STMT_SUBTREE_HAS_TREE_MODIFICATIONS 181
-#define STMT_181_INFO {"STMT_SUBTREE_HAS_TREE_MODIFICATIONS", NULL}
-#define STMT_181 \
+#define STMT_SUBTREE_HAS_TREE_MODIFICATIONS 182
+#define STMT_182_INFO {"STMT_SUBTREE_HAS_TREE_MODIFICATIONS", NULL}
+#define STMT_182 \
"SELECT 1 FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
@@ -1976,9 +1990,9 @@
"LIMIT 1 " \
""
-#define STMT_SUBTREE_HAS_PROP_MODIFICATIONS 182
-#define STMT_182_INFO {"STMT_SUBTREE_HAS_PROP_MODIFICATIONS", NULL}
-#define STMT_182 \
+#define STMT_SUBTREE_HAS_PROP_MODIFICATIONS 183
+#define STMT_183_INFO {"STMT_SUBTREE_HAS_PROP_MODIFICATIONS", NULL}
+#define STMT_183 \
"SELECT 1 FROM actual_node " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 " \
@@ -1987,9 +2001,9 @@
"LIMIT 1 " \
""
-#define STMT_HAS_SWITCHED 183
-#define STMT_183_INFO {"STMT_HAS_SWITCHED", NULL}
-#define STMT_183 \
+#define STMT_HAS_SWITCHED 184
+#define STMT_184_INFO {"STMT_HAS_SWITCHED", NULL}
+#define STMT_184 \
"SELECT 1 " \
"FROM nodes " \
"WHERE wc_id = ?1 " \
@@ -2001,47 +2015,47 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_MOVED_FROM_RELPATH 184
-#define STMT_184_INFO {"STMT_SELECT_MOVED_FROM_RELPATH", NULL}
-#define STMT_184 \
+#define STMT_SELECT_MOVED_FROM_RELPATH 185
+#define STMT_185_INFO {"STMT_SELECT_MOVED_FROM_RELPATH", NULL}
+#define STMT_185 \
"SELECT local_relpath, op_depth FROM nodes " \
"WHERE wc_id = ?1 AND moved_to = ?2 AND op_depth > 0 " \
""
-#define STMT_UPDATE_MOVED_TO_RELPATH 185
-#define STMT_185_INFO {"STMT_UPDATE_MOVED_TO_RELPATH", NULL}
-#define STMT_185 \
+#define STMT_UPDATE_MOVED_TO_RELPATH 186
+#define STMT_186_INFO {"STMT_UPDATE_MOVED_TO_RELPATH", NULL}
+#define STMT_186 \
"UPDATE nodes SET moved_to = ?4 " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?3 " \
""
-#define STMT_CLEAR_MOVED_TO_RELPATH 186
-#define STMT_186_INFO {"STMT_CLEAR_MOVED_TO_RELPATH", NULL}
-#define STMT_186 \
+#define STMT_CLEAR_MOVED_TO_RELPATH 187
+#define STMT_187_INFO {"STMT_CLEAR_MOVED_TO_RELPATH", NULL}
+#define STMT_187 \
"UPDATE nodes SET moved_to = NULL " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth = ?3 " \
""
-#define STMT_CLEAR_MOVED_HERE_RECURSIVE 187
-#define STMT_187_INFO {"STMT_CLEAR_MOVED_HERE_RECURSIVE", NULL}
-#define STMT_187 \
+#define STMT_CLEAR_MOVED_HERE_RECURSIVE 188
+#define STMT_188_INFO {"STMT_CLEAR_MOVED_HERE_RECURSIVE", NULL}
+#define STMT_188 \
"UPDATE nodes SET moved_here = NULL " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
" AND op_depth = ?3 " \
""
-#define STMT_SELECT_MOVED_HERE_CHILDREN 188
-#define STMT_188_INFO {"STMT_SELECT_MOVED_HERE_CHILDREN", NULL}
-#define STMT_188 \
+#define STMT_SELECT_MOVED_HERE_CHILDREN 189
+#define STMT_189_INFO {"STMT_SELECT_MOVED_HERE_CHILDREN", NULL}
+#define STMT_189 \
"SELECT moved_to, local_relpath FROM nodes " \
"WHERE wc_id = ?1 AND op_depth > 0 " \
" AND (((moved_to) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((moved_to) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_SELECT_MOVED_FOR_DELETE 189
-#define STMT_189_INFO {"STMT_SELECT_MOVED_FOR_DELETE", NULL}
-#define STMT_189 \
+#define STMT_SELECT_MOVED_FOR_DELETE 190
+#define STMT_190_INFO {"STMT_SELECT_MOVED_FOR_DELETE", NULL}
+#define STMT_190 \
"SELECT local_relpath, moved_to, op_depth, " \
" (SELECT CASE WHEN r.moved_here THEN r.op_depth END FROM nodes r " \
" WHERE r.wc_id = ?1 " \
@@ -2055,9 +2069,9 @@
" AND op_depth >= ?3 " \
""
-#define STMT_SELECT_MOVED_FROM_FOR_DELETE 190
-#define STMT_190_INFO {"STMT_SELECT_MOVED_FROM_FOR_DELETE", NULL}
-#define STMT_190 \
+#define STMT_SELECT_MOVED_FROM_FOR_DELETE 191
+#define STMT_191_INFO {"STMT_SELECT_MOVED_FROM_FOR_DELETE", NULL}
+#define STMT_191 \
"SELECT local_relpath, op_depth, " \
" (SELECT CASE WHEN r.moved_here THEN r.op_depth END FROM nodes r " \
" WHERE r.wc_id = ?1 " \
@@ -2068,25 +2082,25 @@
"WHERE wc_id = ?1 AND moved_to = ?2 AND op_depth > 0 " \
""
-#define STMT_UPDATE_MOVED_TO_DESCENDANTS 191
-#define STMT_191_INFO {"STMT_UPDATE_MOVED_TO_DESCENDANTS", NULL}
-#define STMT_191 \
+#define STMT_UPDATE_MOVED_TO_DESCENDANTS 192
+#define STMT_192_INFO {"STMT_UPDATE_MOVED_TO_DESCENDANTS", NULL}
+#define STMT_192 \
"UPDATE nodes SET moved_to = (CASE WHEN (?2) = '' THEN (CASE WHEN (?3) = '' THEN (moved_to) WHEN (moved_to) = '' THEN (?3) ELSE (?3) || '/' || (moved_to) END) WHEN (?3) = '' THEN (CASE WHEN (?2) = '' THEN (moved_to) WHEN SUBSTR((moved_to), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(moved_to) THEN '' WHEN SUBSTR((moved_to), LENGTH(?2)+1, 1) = '/' THEN SUBSTR((moved_to), LENGTH(?2)+2) END END) WHEN SUBSTR((moved_to), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(moved_to) THEN (?3) WHEN SUBSTR((moved_to), LENGTH(?2)+1, 1) = '/' THEN (?3) || SUBSTR((moved_to), LENGTH(?2)+1) END END) " \
" WHERE wc_id = ?1 " \
" AND (((moved_to) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((moved_to) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_CLEAR_MOVED_TO_DESCENDANTS 192
-#define STMT_192_INFO {"STMT_CLEAR_MOVED_TO_DESCENDANTS", NULL}
-#define STMT_192 \
+#define STMT_CLEAR_MOVED_TO_DESCENDANTS 193
+#define STMT_193_INFO {"STMT_CLEAR_MOVED_TO_DESCENDANTS", NULL}
+#define STMT_193 \
"UPDATE nodes SET moved_to = NULL " \
" WHERE wc_id = ?1 " \
" AND (((moved_to) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((moved_to) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_SELECT_MOVED_PAIR3 193
-#define STMT_193_INFO {"STMT_SELECT_MOVED_PAIR3", NULL}
-#define STMT_193 \
+#define STMT_SELECT_MOVED_PAIR3 194
+#define STMT_194_INFO {"STMT_SELECT_MOVED_PAIR3", NULL}
+#define STMT_194 \
"SELECT n.local_relpath, d.moved_to, d.op_depth, n.kind " \
"FROM nodes n " \
"JOIN nodes d ON d.wc_id = ?1 AND d.local_relpath = n.local_relpath " \
@@ -2112,9 +2126,9 @@
"ORDER BY n.local_relpath " \
""
-#define STMT_SELECT_MOVED_OUTSIDE 194
-#define STMT_194_INFO {"STMT_SELECT_MOVED_OUTSIDE", NULL}
-#define STMT_194 \
+#define STMT_SELECT_MOVED_OUTSIDE 195
+#define STMT_195_INFO {"STMT_SELECT_MOVED_OUTSIDE", NULL}
+#define STMT_195 \
"SELECT local_relpath, moved_to, op_depth FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (local_relpath = ?2 OR (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END))) " \
@@ -2123,9 +2137,9 @@
" AND NOT (((moved_to) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((moved_to) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
""
-#define STMT_SELECT_MOVED_DESCENDANTS_SRC 195
-#define STMT_195_INFO {"STMT_SELECT_MOVED_DESCENDANTS_SRC", NULL}
-#define STMT_195 \
+#define STMT_SELECT_MOVED_DESCENDANTS_SRC 196
+#define STMT_196_INFO {"STMT_SELECT_MOVED_DESCENDANTS_SRC", NULL}
+#define STMT_196 \
"SELECT s.op_depth, n.local_relpath, n.kind, n.repos_path, s.moved_to " \
"FROM nodes n " \
"JOIN nodes s ON s.wc_id = n.wc_id AND s.local_relpath = n.local_relpath " \
@@ -2139,9 +2153,9 @@
" AND s.moved_to IS NOT NULL " \
""
-#define STMT_COMMIT_UPDATE_ORIGIN 196
-#define STMT_196_INFO {"STMT_COMMIT_UPDATE_ORIGIN", NULL}
-#define STMT_196 \
+#define STMT_COMMIT_UPDATE_ORIGIN 197
+#define STMT_197_INFO {"STMT_COMMIT_UPDATE_ORIGIN", NULL}
+#define STMT_197 \
"UPDATE nodes SET repos_id = ?4, " \
" repos_path = (CASE WHEN (?2) = '' THEN (CASE WHEN (?5) = '' THEN (local_relpath) WHEN (local_relpath) = '' THEN (?5) ELSE (?5) || '/' || (local_relpath) END) WHEN (?5) = '' THEN (CASE WHEN (?2) = '' THEN (local_relpath) WHEN SUBSTR((local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(local_relpath) THEN '' WHEN SUBSTR((local_relpath), LENGTH(?2)+1, 1) = '/' THEN SUBSTR((local_relpath), LENGTH(?2)+2) END END) WHEN SUBSTR((local_relpath), 1, LENGTH(?2)) = (?2) THEN CASE WHEN LENGTH(?2) = LENGTH(local_relpath) THEN (?5) WHEN SUBSTR((local_relpath), LENGTH(?2)+1, 1) = '/' THEN (?5) || SUBSTR((local_relpath), LENGTH(?2)+1) END END), " \
" revision = ?6 " \
@@ -2151,16 +2165,16 @@
" AND op_depth = ?3 " \
""
-#define STMT_HAS_LAYER_BETWEEN 197
-#define STMT_197_INFO {"STMT_HAS_LAYER_BETWEEN", NULL}
-#define STMT_197 \
+#define STMT_HAS_LAYER_BETWEEN 198
+#define STMT_198_INFO {"STMT_HAS_LAYER_BETWEEN", NULL}
+#define STMT_198 \
"SELECT 1 FROM NODES " \
"WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth > ?3 AND op_depth < ?4 " \
""
-#define STMT_SELECT_REPOS_PATH_REVISION 198
-#define STMT_198_INFO {"STMT_SELECT_REPOS_PATH_REVISION", NULL}
-#define STMT_198 \
+#define STMT_SELECT_REPOS_PATH_REVISION 199
+#define STMT_199_INFO {"STMT_SELECT_REPOS_PATH_REVISION", NULL}
+#define STMT_199 \
"SELECT local_relpath, repos_path, revision FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -2168,17 +2182,17 @@
"ORDER BY local_relpath " \
""
-#define STMT_SELECT_HAS_NON_FILE_CHILDREN 199
-#define STMT_199_INFO {"STMT_SELECT_HAS_NON_FILE_CHILDREN", NULL}
-#define STMT_199 \
+#define STMT_SELECT_HAS_NON_FILE_CHILDREN 200
+#define STMT_200_INFO {"STMT_SELECT_HAS_NON_FILE_CHILDREN", NULL}
+#define STMT_200 \
"SELECT 1 FROM nodes " \
"WHERE wc_id = ?1 AND parent_relpath = ?2 AND op_depth = ?3 AND kind != 'file' " \
"LIMIT 1 " \
""
-#define STMT_SELECT_HAS_GRANDCHILDREN 200
-#define STMT_200_INFO {"STMT_SELECT_HAS_GRANDCHILDREN", NULL}
-#define STMT_200 \
+#define STMT_SELECT_HAS_GRANDCHILDREN 201
+#define STMT_201_INFO {"STMT_SELECT_HAS_GRANDCHILDREN", NULL}
+#define STMT_201 \
"SELECT 1 FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((parent_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((parent_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -2187,24 +2201,24 @@
"LIMIT 1 " \
""
-#define STMT_SELECT_ALL_NODES 201
-#define STMT_201_INFO {"STMT_SELECT_ALL_NODES", NULL}
-#define STMT_201 \
+#define STMT_SELECT_ALL_NODES 202
+#define STMT_202_INFO {"STMT_SELECT_ALL_NODES", NULL}
+#define STMT_202 \
"SELECT op_depth, local_relpath, parent_relpath, file_external FROM nodes " \
"WHERE wc_id = ?1 " \
""
-#define STMT_UPDATE_IPROP 202
-#define STMT_202_INFO {"STMT_UPDATE_IPROP", NULL}
-#define STMT_202 \
+#define STMT_UPDATE_IPROP 203
+#define STMT_203_INFO {"STMT_UPDATE_IPROP", NULL}
+#define STMT_203 \
"UPDATE nodes " \
"SET inherited_props = ?3 " \
"WHERE (wc_id = ?1 AND local_relpath = ?2 AND op_depth = 0) " \
""
-#define STMT_SELECT_IPROPS_NODE 203
-#define STMT_203_INFO {"STMT_SELECT_IPROPS_NODE", NULL}
-#define STMT_203 \
+#define STMT_SELECT_IPROPS_NODE 204
+#define STMT_204_INFO {"STMT_SELECT_IPROPS_NODE", NULL}
+#define STMT_204 \
"SELECT local_relpath, repos_path FROM nodes " \
"WHERE wc_id = ?1 " \
" AND local_relpath = ?2 " \
@@ -2212,9 +2226,9 @@
" AND (inherited_props not null) " \
""
-#define STMT_SELECT_IPROPS_RECURSIVE 204
-#define STMT_204_INFO {"STMT_SELECT_IPROPS_RECURSIVE", NULL}
-#define STMT_204 \
+#define STMT_SELECT_IPROPS_RECURSIVE 205
+#define STMT_205_INFO {"STMT_SELECT_IPROPS_RECURSIVE", NULL}
+#define STMT_205 \
"SELECT local_relpath, repos_path FROM nodes " \
"WHERE wc_id = ?1 " \
" AND (((local_relpath) > (CASE (?2) WHEN '' THEN '' ELSE (?2) || '/' END)) AND ((local_relpath) < CASE (?2) WHEN '' THEN X'FFFF' ELSE (?2) || '0' END)) " \
@@ -2222,9 +2236,9 @@
" AND (inherited_props not null) " \
""
-#define STMT_SELECT_IPROPS_CHILDREN 205
-#define STMT_205_INFO {"STMT_SELECT_IPROPS_CHILDREN", NULL}
-#define STMT_205 \
+#define STMT_SELECT_IPROPS_CHILDREN 206
+#define STMT_206_INFO {"STMT_SELECT_IPROPS_CHILDREN", NULL}
+#define STMT_206 \
"SELECT local_relpath, repos_path FROM nodes " \
"WHERE wc_id = ?1 " \
" AND parent_relpath = ?2 " \
@@ -2232,16 +2246,30 @@
" AND (inherited_props not null) " \
""
-#define STMT_HAVE_STAT1_TABLE 206
-#define STMT_206_INFO {"STMT_HAVE_STAT1_TABLE", NULL}
-#define STMT_206 \
+#define STMT_HAVE_STAT1_TABLE 207
+#define STMT_207_INFO {"STMT_HAVE_STAT1_TABLE", NULL}
+#define STMT_207 \
"SELECT 1 FROM sqlite_master WHERE name='sqlite_stat1' AND type='table' " \
"LIMIT 1 " \
""
-#define STMT_CREATE_SCHEMA 207
-#define STMT_207_INFO {"STMT_CREATE_SCHEMA", NULL}
-#define STMT_207 \
+#define STMT_SELECT_COPIES_OF_REPOS_RELPATH 208
+#define STMT_208_INFO {"STMT_SELECT_COPIES_OF_REPOS_RELPATH", NULL}
+#define STMT_208 \
+ "SELECT local_relpath " \
+ "FROM nodes n " \
+ "WHERE wc_id = ?1 AND repos_path = ?2 AND kind = ?3 " \
+ " AND presence = 'normal' " \
+ " AND op_depth = (SELECT MAX(op_depth) " \
+ " FROM NODES w " \
+ " WHERE w.wc_id = ?1 " \
+ " AND w.local_relpath = n.local_relpath) " \
+ "ORDER BY local_relpath ASC " \
+ ""
+
+#define STMT_CREATE_SCHEMA 209
+#define STMT_209_INFO {"STMT_CREATE_SCHEMA", NULL}
+#define STMT_209 \
"CREATE TABLE REPOSITORY ( " \
" id INTEGER PRIMARY KEY AUTOINCREMENT, " \
" root TEXT UNIQUE NOT NULL, " \
@@ -2382,9 +2410,9 @@
"; " \
""
-#define STMT_INSTALL_SCHEMA_STATISTICS 208
-#define STMT_208_INFO {"STMT_INSTALL_SCHEMA_STATISTICS", NULL}
-#define STMT_208 \
+#define STMT_INSTALL_SCHEMA_STATISTICS 210
+#define STMT_210_INFO {"STMT_INSTALL_SCHEMA_STATISTICS", NULL}
+#define STMT_210 \
"ANALYZE sqlite_master; " \
"DELETE FROM sqlite_stat1 " \
"WHERE tbl in ('NODES', 'ACTUAL_NODE', 'LOCK', 'WC_LOCK', 'EXTERNALS'); " \
@@ -2409,9 +2437,9 @@
"ANALYZE sqlite_master; " \
""
-#define STMT_UPGRADE_TO_30 209
-#define STMT_209_INFO {"STMT_UPGRADE_TO_30", NULL}
-#define STMT_209 \
+#define STMT_UPGRADE_TO_30 211
+#define STMT_211_INFO {"STMT_UPGRADE_TO_30", NULL}
+#define STMT_211 \
"CREATE UNIQUE INDEX IF NOT EXISTS I_NODES_MOVED " \
"ON NODES (wc_id, moved_to, op_depth); " \
"CREATE INDEX IF NOT EXISTS I_PRISTINE_MD5 ON PRISTINE (md5_checksum); " \
@@ -2419,9 +2447,9 @@
"UPDATE nodes SET file_external=1 WHERE file_external IS NOT NULL; " \
""
-#define STMT_UPGRADE_30_SELECT_CONFLICT_SEPARATE 210
-#define STMT_210_INFO {"STMT_UPGRADE_30_SELECT_CONFLICT_SEPARATE", NULL}
-#define STMT_210 \
+#define STMT_UPGRADE_30_SELECT_CONFLICT_SEPARATE 212
+#define STMT_212_INFO {"STMT_UPGRADE_30_SELECT_CONFLICT_SEPARATE", NULL}
+#define STMT_212 \
"SELECT wc_id, local_relpath, " \
" conflict_old, conflict_working, conflict_new, prop_reject, tree_conflict_data " \
"FROM actual_node " \
@@ -2433,18 +2461,18 @@
"ORDER by wc_id, local_relpath " \
""
-#define STMT_UPGRADE_30_SET_CONFLICT 211
-#define STMT_211_INFO {"STMT_UPGRADE_30_SET_CONFLICT", NULL}
-#define STMT_211 \
+#define STMT_UPGRADE_30_SET_CONFLICT 213
+#define STMT_213_INFO {"STMT_UPGRADE_30_SET_CONFLICT", NULL}
+#define STMT_213 \
"UPDATE actual_node SET conflict_data = ?3, conflict_old = NULL, " \
" conflict_working = NULL, conflict_new = NULL, prop_reject = NULL, " \
" tree_conflict_data = NULL " \
"WHERE wc_id = ?1 and local_relpath = ?2 " \
""
-#define STMT_UPGRADE_TO_31 212
-#define STMT_212_INFO {"STMT_UPGRADE_TO_31", NULL}
-#define STMT_212 \
+#define STMT_UPGRADE_TO_31 214
+#define STMT_214_INFO {"STMT_UPGRADE_TO_31", NULL}
+#define STMT_214 \
"ALTER TABLE NODES ADD COLUMN inherited_props BLOB; " \
"DROP INDEX IF EXISTS I_ACTUAL_CHANGELIST; " \
"DROP INDEX IF EXISTS I_EXTERNALS_PARENT; " \
@@ -2457,9 +2485,9 @@
"PRAGMA user_version = 31; " \
""
-#define STMT_UPGRADE_31_SELECT_WCROOT_NODES 213
-#define STMT_213_INFO {"STMT_UPGRADE_31_SELECT_WCROOT_NODES", NULL}
-#define STMT_213 \
+#define STMT_UPGRADE_31_SELECT_WCROOT_NODES 215
+#define STMT_215_INFO {"STMT_UPGRADE_31_SELECT_WCROOT_NODES", NULL}
+#define STMT_215 \
"SELECT l.wc_id, l.local_relpath FROM nodes as l " \
"LEFT OUTER JOIN nodes as r " \
"ON l.wc_id = r.wc_id " \
@@ -2511,9 +2539,9 @@
"DROP TABLE ACTUAL_NODE_BACKUP; " \
""
-#define STMT_VERIFICATION_TRIGGERS 214
-#define STMT_214_INFO {"STMT_VERIFICATION_TRIGGERS", NULL}
-#define STMT_214 \
+#define STMT_VERIFICATION_TRIGGERS 216
+#define STMT_216_INFO {"STMT_VERIFICATION_TRIGGERS", NULL}
+#define STMT_216 \
"CREATE TEMPORARY TRIGGER no_repository_updates BEFORE UPDATE ON repository " \
"BEGIN " \
" SELECT RAISE(FAIL, 'Updates to REPOSITORY are not allowed.'); " \
@@ -2552,9 +2580,9 @@
"END; " \
""
-#define STMT_STATIC_VERIFY 215
-#define STMT_215_INFO {"STMT_STATIC_VERIFY", NULL}
-#define STMT_215 \
+#define STMT_STATIC_VERIFY 217
+#define STMT_217_INFO {"STMT_STATIC_VERIFY", NULL}
+#define STMT_217 \
"SELECT local_relpath, op_depth, 1, 'Invalid parent relpath set in NODES' " \
"FROM nodes n WHERE local_relpath != '' " \
" AND (parent_relpath IS NULL " \
@@ -2943,6 +2971,8 @@
STMT_213, \
STMT_214, \
STMT_215, \
+ STMT_216, \
+ STMT_217, \
NULL \
}
@@ -3164,5 +3194,7 @@
STMT_213_INFO, \
STMT_214_INFO, \
STMT_215_INFO, \
+ STMT_216_INFO, \
+ STMT_217_INFO, \
{NULL, NULL} \
}
diff --git a/subversion/libsvn_wc/wc-queries.sql b/subversion/libsvn_wc/wc-queries.sql
index 86cf9216a058..962e57dc16c2 100644
--- a/subversion/libsvn_wc/wc-queries.sql
+++ b/subversion/libsvn_wc/wc-queries.sql
@@ -117,6 +117,17 @@ WHERE wc_id = ?1 AND local_relpath = ?2 AND op_depth < ?3
ORDER BY op_depth DESC
LIMIT 1
+-- STMT_SELECT_PRESENT_HIGHEST_WORKING_NODES_BY_BASENAME_AND_KIND
+SELECT presence, local_relpath
+FROM nodes n
+WHERE wc_id = ?1 AND local_relpath = RELPATH_JOIN(parent_relpath, ?2)
+ AND kind = ?3
+ AND presence in (MAP_NORMAL, MAP_INCOMPLETE)
+ AND op_depth = (SELECT MAX(op_depth)
+ FROM NODES w
+ WHERE w.wc_id = ?1
+ AND w.local_relpath = n.local_relpath)
+
-- STMT_SELECT_ACTUAL_NODE
SELECT changelist, properties, conflict_data
FROM actual_node
@@ -249,7 +260,7 @@ WHERE wc_id = ?1 AND IS_STRICT_DESCENDANT_OF(local_relpath, ?2)
-- STMT_DELETE_BASE_RECURSIVE
DELETE FROM nodes
-WHERE wc_id = ?1 AND (local_relpath = ?2
+WHERE wc_id = ?1 AND (local_relpath = ?2
OR IS_STRICT_DESCENDANT_OF(local_relpath, ?2))
AND op_depth = 0
@@ -1785,6 +1796,17 @@ WHERE wc_id = ?1
SELECT 1 FROM sqlite_master WHERE name='sqlite_stat1' AND type='table'
LIMIT 1
+-- STMT_SELECT_COPIES_OF_REPOS_RELPATH
+SELECT local_relpath
+FROM nodes n
+WHERE wc_id = ?1 AND repos_path = ?2 AND kind = ?3
+ AND presence = MAP_NORMAL
+ AND op_depth = (SELECT MAX(op_depth)
+ FROM NODES w
+ WHERE w.wc_id = ?1
+ AND w.local_relpath = n.local_relpath)
+ORDER BY local_relpath ASC
+
/* ------------------------------------------------------------------------- */
/* Grab all the statements related to the schema. */
diff --git a/subversion/libsvn_wc/wc.h b/subversion/libsvn_wc/wc.h
index f8bbebd93ade..c8da7a906c21 100644
--- a/subversion/libsvn_wc/wc.h
+++ b/subversion/libsvn_wc/wc.h
@@ -289,6 +289,7 @@ struct svn_wc_traversal_info_t
#define SVN_WC__ADM_TMP "tmp"
#define SVN_WC__ADM_PRISTINE "pristine"
#define SVN_WC__ADM_NONEXISTENT_PATH "nonexistent-path"
+#define SVN_WC__ADM_EXPERIMENTAL "experimental"
/* The basename of the ".prej" file, if a directory ever has property
conflicts. This .prej file will appear *within* the conflicted
diff --git a/subversion/libsvn_wc/wc_db.c b/subversion/libsvn_wc/wc_db.c
index bc87b2f9d8d9..c76a8b1b9447 100644
--- a/subversion/libsvn_wc/wc_db.c
+++ b/subversion/libsvn_wc/wc_db.c
@@ -2374,7 +2374,7 @@ db_base_remove(svn_wc__db_wcroot_t *wcroot,
/* For file externals we only want to place a not present marker
if there is a BASE parent */
-
+
svn_relpath_split(&parent_local_relpath, &name, local_relpath,
scratch_pool);
@@ -6702,7 +6702,7 @@ svn_wc__db_op_mark_resolved_internal(svn_wc__db_wcroot_t *wcroot,
return SVN_NO_ERROR;
conflicts = svn_skel__parse(conflict_data, conflict_len, scratch_pool);
-
+
SVN_ERR(svn_wc__conflict_skel_resolve(&resolved_all, conflicts,
db, wcroot->abspath,
@@ -6839,7 +6839,7 @@ revert_maybe_raise_moved_away(svn_wc__db_wcroot_t * wcroot,
}
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason, &action,
- NULL,
+ NULL, NULL,
db, wcroot->abspath,
conflict,
scratch_pool,
@@ -7991,7 +7991,7 @@ struct op_delete_baton_t {
* Note that the following sequence results in the same DB state:
* mv A B; mv B/F B/G
* We do not care about the order the moves were performed in.
- * For details, see http://wiki.apache.org/subversion/MultiLayerMoves
+ * For details, see https://cwiki.apache.org/confluence/display/SVN/MultiLayerMoves
*/
struct moved_node_t {
/* The source of the move. */
@@ -8396,7 +8396,7 @@ delete_node(void *baton,
scratch_pool, iterpool));
if (!mn->local_relpath)
- svn_sort__array_delete(moved_nodes, i--, 1);
+ SVN_ERR(svn_sort__array_delete2(moved_nodes, i--, 1));
}
}
@@ -10804,7 +10804,7 @@ db_read_inherited_props(apr_array_header_t **inherited_props,
iprop_elt->prop_hash = node_props;
/* Build the output array in depth-first order. */
- svn_sort__array_insert(iprops, &iprop_elt, 0);
+ SVN_ERR(svn_sort__array_insert2(iprops, &iprop_elt, 0));
}
}
}
@@ -10840,7 +10840,7 @@ db_read_inherited_props(apr_array_header_t **inherited_props,
/* If we didn't filter everything then keep this iprop. */
if (apr_hash_count(cached_iprop->prop_hash))
- svn_sort__array_insert(iprops, &cached_iprop, 0);
+ SVN_ERR(svn_sort__array_insert2(iprops, &cached_iprop, 0));
}
}
@@ -16525,8 +16525,8 @@ db_process_commit_queue(svn_wc__db_t *db,
iterpool),
iterpool, iterpool));
- lock_remove_txn(queue->wcroot, cqi->local_relpath, work_item,
- iterpool);
+ SVN_ERR(lock_remove_txn(queue->wcroot, cqi->local_relpath,
+ work_item, iterpool));
}
if (cqi->remove_changelist)
SVN_ERR(svn_wc__db_op_set_changelist(db,
@@ -16578,12 +16578,12 @@ svn_wc__db_process_commit_queue(svn_wc__db_t *db,
}
svn_error_t *
-svn_wc__find_repos_node_in_wc(apr_array_header_t **local_abspath_list,
- svn_wc__db_t *db,
- const char *wri_abspath,
- const char *repos_relpath,
- apr_pool_t *result_pool,
- apr_pool_t *scratch_pool)
+svn_wc__db_find_repos_node_in_wc(apr_array_header_t **local_abspath_list,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *repos_relpath,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
{
svn_wc__db_wcroot_t *wcroot;
const char *wri_relpath;
@@ -16616,7 +16616,94 @@ svn_wc__find_repos_node_in_wc(apr_array_header_t **local_abspath_list,
SVN_ERR(svn_sqlite__step(&have_row, stmt));
}
-
+
+ return svn_error_trace(svn_sqlite__reset(stmt));
+}
+
+svn_error_t *
+svn_wc__db_find_working_nodes_with_basename(apr_array_header_t **local_abspaths,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *basename,
+ svn_node_kind_t kind,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
+{
+ svn_wc__db_wcroot_t *wcroot;
+ const char *wri_relpath;
+ svn_sqlite__stmt_t *stmt;
+ svn_boolean_t have_row;
+
+ SVN_ERR_ASSERT(svn_dirent_is_absolute(wri_abspath));
+
+ SVN_ERR(svn_wc__db_wcroot_parse_local_abspath(&wcroot, &wri_relpath, db,
+ wri_abspath, scratch_pool,
+ scratch_pool));
+ VERIFY_USABLE_WCROOT(wcroot);
+
+ SVN_ERR(svn_sqlite__get_statement(&stmt, wcroot->sdb,
+ STMT_SELECT_PRESENT_HIGHEST_WORKING_NODES_BY_BASENAME_AND_KIND));
+ SVN_ERR(svn_sqlite__bindf(stmt, "ist", wcroot->wc_id, basename,
+ kind_map, kind));
+ SVN_ERR(svn_sqlite__step(&have_row, stmt));
+
+ *local_abspaths = apr_array_make(result_pool, 1, sizeof(const char *));
+
+ while (have_row)
+ {
+ const char *local_relpath;
+ const char *local_abspath;
+
+ local_relpath = svn_sqlite__column_text(stmt, 1, NULL);
+ local_abspath = svn_dirent_join(wcroot->abspath, local_relpath,
+ result_pool);
+ APR_ARRAY_PUSH(*local_abspaths, const char *) = local_abspath;
+ SVN_ERR(svn_sqlite__step(&have_row, stmt));
+ }
+
return svn_error_trace(svn_sqlite__reset(stmt));
}
+svn_error_t *
+svn_wc__db_find_copies_of_repos_path(apr_array_header_t **local_abspaths,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *repos_relpath,
+ svn_node_kind_t kind,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
+{
+ svn_wc__db_wcroot_t *wcroot;
+ const char *wri_relpath;
+ svn_sqlite__stmt_t *stmt;
+ svn_boolean_t have_row;
+
+ SVN_ERR_ASSERT(svn_dirent_is_absolute(wri_abspath));
+
+ SVN_ERR(svn_wc__db_wcroot_parse_local_abspath(&wcroot, &wri_relpath, db,
+ wri_abspath, scratch_pool,
+ scratch_pool));
+ VERIFY_USABLE_WCROOT(wcroot);
+
+ SVN_ERR(svn_sqlite__get_statement(&stmt, wcroot->sdb,
+ STMT_SELECT_COPIES_OF_REPOS_RELPATH));
+ SVN_ERR(svn_sqlite__bindf(stmt, "ist", wcroot->wc_id, repos_relpath,
+ kind_map, kind));
+ SVN_ERR(svn_sqlite__step(&have_row, stmt));
+
+ *local_abspaths = apr_array_make(result_pool, 1, sizeof(const char *));
+
+ while (have_row)
+ {
+ const char *local_relpath;
+ const char *local_abspath;
+
+ local_relpath = svn_sqlite__column_text(stmt, 0, NULL);
+ local_abspath = svn_dirent_join(wcroot->abspath, local_relpath,
+ result_pool);
+ APR_ARRAY_PUSH(*local_abspaths, const char *) = local_abspath;
+ SVN_ERR(svn_sqlite__step(&have_row, stmt));
+ }
+
+ return svn_error_trace(svn_sqlite__reset(stmt));
+}
diff --git a/subversion/libsvn_wc/wc_db.h b/subversion/libsvn_wc/wc_db.h
index 0bf6432100fb..a7cc1688aeb9 100644
--- a/subversion/libsvn_wc/wc_db.h
+++ b/subversion/libsvn_wc/wc_db.h
@@ -3496,12 +3496,48 @@ svn_wc__required_lock_for_resolve(const char **required_abspath,
* which has been replaced.
*/
svn_error_t *
-svn_wc__find_repos_node_in_wc(apr_array_header_t **local_abspath_list,
- svn_wc__db_t *db,
- const char *wri_abspath,
- const char *repos_relpath,
- apr_pool_t *result_pool,
- apr_pool_t *scratch_pool);
+svn_wc__db_find_repos_node_in_wc(apr_array_header_t **local_abspath_list,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *repos_relpath,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
+
+/* Return an array of const char * elements, which represent local absolute
+ * paths for nodes, within the working copy indicated by WRI_ABSPATH, which
+ * have a basename matching BASENAME and have node kind KIND.
+ * If no such nodes exist, return an empty array.
+ *
+ * This function returns only paths to nodes which are present in the highest
+ * layer of the WC. In other words, paths to deleted and/or excluded nodes are
+ * never returned.
+ */
+svn_error_t *
+svn_wc__db_find_working_nodes_with_basename(apr_array_header_t **local_abspaths,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *basename,
+ svn_node_kind_t kind,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
+
+/* Return an array of const char * elements, which represent local absolute
+ * paths for nodes, within the working copy indicated by WRI_ABSPATH, which
+ * are copies of REPOS_RELPATH and have node kind KIND.
+ * If no such nodes exist, return an empty array.
+ *
+ * This function returns only paths to nodes which are present in the highest
+ * layer of the WC. In other words, paths to deleted and/or excluded nodes are
+ * never returned.
+ */
+svn_error_t *
+svn_wc__db_find_copies_of_repos_path(apr_array_header_t **local_abspaths,
+ svn_wc__db_t *db,
+ const char *wri_abspath,
+ const char *repos_relpath,
+ svn_node_kind_t kind,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
/* @} */
typedef svn_error_t * (*svn_wc__db_verify_cb_t)(void *baton,
diff --git a/subversion/libsvn_wc/wc_db_update_move.c b/subversion/libsvn_wc/wc_db_update_move.c
index ba7117581ec1..e420a845ee53 100644
--- a/subversion/libsvn_wc/wc_db_update_move.c
+++ b/subversion/libsvn_wc/wc_db_update_move.c
@@ -95,7 +95,7 @@
* to avoid tree conflicts where the "incoming" and "local" change both
* originated in the working copy, because the resolver code cannot handle
* such tree conflicts at present.
- *
+ *
* The whole drive occurs as one single wc.db transaction. At the end
* of the transaction the destination NODES table should have a WORKING
* layer that is equivalent to the WORKING layer found in the copied victim
@@ -411,6 +411,11 @@ create_tree_conflict(svn_skel_t **conflict_p,
? svn_dirent_join(wcroot->abspath,
move_src_op_root_relpath, scratch_pool)
: NULL;
+ const char *move_dst_op_root_abspath
+ = dst_op_root_relpath
+ ? svn_dirent_join(wcroot->abspath,
+ dst_op_root_relpath, scratch_pool)
+ : NULL;
const char *old_repos_relpath_part
= old_repos_relpath && old_version
? svn_relpath_skip_ancestor(old_version->path_in_repos,
@@ -468,7 +473,7 @@ create_tree_conflict(svn_skel_t **conflict_p,
SVN_ERR(svn_wc__conflict_read_tree_conflict(&existing_reason,
&existing_action,
- &existing_abspath,
+ &existing_abspath, NULL,
db, wcroot->abspath,
conflict,
scratch_pool,
@@ -500,6 +505,7 @@ create_tree_conflict(svn_skel_t **conflict_p,
reason,
action,
move_src_op_root_abspath,
+ move_dst_op_root_abspath,
result_pool,
scratch_pool));
@@ -1050,7 +1056,7 @@ tc_editor_incoming_add_file(node_move_baton_t *nmb,
SVN_ERR(svn_wc__wq_build_file_remove(&work_item, b->db,
b->wcroot->abspath, src_abspath,
scratch_pool, scratch_pool));
-
+
work_items = svn_wc__wq_merge(work_items, work_item, scratch_pool);
}
@@ -2169,11 +2175,12 @@ suitable_for_move(svn_wc__db_wcroot_t *wcroot,
while (have_row)
{
svn_revnum_t node_revision = svn_sqlite__column_revnum(stmt, 2);
- const char *child_relpath = svn_sqlite__column_text(stmt, 0, NULL);
+ const char *child_relpath;
const char *relpath;
svn_pool_clear(iterpool);
+ child_relpath = svn_sqlite__column_text(stmt, 0, iterpool);
relpath = svn_relpath_skip_ancestor(local_relpath, child_relpath);
relpath = svn_relpath_join(repos_relpath, relpath, iterpool);
@@ -2520,7 +2527,7 @@ update_incoming_moved_node(node_move_baton_t *nmb,
SVN_ERR(svn_stream_open_unique(&temp_stream, &temp_abspath,
wctemp_abspath, svn_io_file_del_none,
scratch_pool, scratch_pool));
- err = svn_stream_copy3(working_stream, temp_stream,
+ err = svn_stream_copy3(working_stream, temp_stream,
b->cancel_func, b->cancel_baton,
scratch_pool);
if (err && err->apr_err == SVN_ERR_CANCELLED)
@@ -2685,7 +2692,7 @@ update_incoming_move(svn_revnum_t *old_rev,
* recorded for any tree conflicts created during the editor drive.
* We assume this path contains no local changes, and create local changes
* in DST_RELPATH corresponding to changes contained in the conflict victim.
- *
+ *
* DST_OP_DEPTH is used to infer the "op-root" of the incoming move. This
* "op-root" is virtual because all nodes belonging to the incoming move
* live in the BASE tree. It is used for constructing repository paths
@@ -2981,7 +2988,7 @@ tc_editor_update_add_new_file(added_node_baton_t *nb,
nb->skip = TRUE;
return SVN_NO_ERROR;
}
-
+
/* Check for obstructions. */
local_abspath = svn_dirent_join(nb->b->wcroot->abspath, nb->local_relpath,
scratch_pool);
@@ -3582,7 +3589,7 @@ svn_wc__db_update_local_add(svn_wc__db_t *db,
VERIFY_USABLE_WCROOT(wcroot);
SVN_WC__DB_WITH_TXN(update_local_add(&new_rev, db, wcroot,
- local_relpath,
+ local_relpath,
cancel_func, cancel_baton,
scratch_pool),
wcroot);
@@ -4099,7 +4106,7 @@ fetch_conflict_details(int *src_op_depth,
SVN_ERR(svn_wc__conflict_read_tree_conflict(&reason,
action,
- &move_src_op_root_abspath,
+ &move_src_op_root_abspath, NULL,
db, local_abspath,
conflict_skel, result_pool,
scratch_pool));
@@ -4251,7 +4258,7 @@ svn_wc__db_op_raise_moved_away(svn_wc__db_t *db,
scratch_pool),
wcroot);
- /* These version numbers are valid for update/switch notifications
+ /* These version numbers are valid for update/switch notifications
only! */
SVN_ERR(svn_wc__db_update_move_list_notify(wcroot,
(left_version
diff --git a/subversion/libsvn_wc/wc_db_wcroot.c b/subversion/libsvn_wc/wc_db_wcroot.c
index 1cfca3d1c7c7..c4f8c3bd4706 100644
--- a/subversion/libsvn_wc/wc_db_wcroot.c
+++ b/subversion/libsvn_wc/wc_db_wcroot.c
@@ -528,6 +528,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
const char *adm_relpath;
/* Non-NULL if WCROOT is found through a symlink: */
const char *symlink_wcroot_abspath = NULL;
+ apr_pool_t *iterpool;
/* ### we need more logic for finding the database (if it is located
### outside of the wcroot) and then managing all of that within DB.
@@ -613,16 +614,20 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
database in the right place. If we find it... great! If not, then
peel off some components, and try again. */
+ iterpool = svn_pool_create(scratch_pool);
adm_relpath = svn_wc_get_adm_dir(scratch_pool);
while (TRUE)
{
svn_error_t *err;
svn_node_kind_t adm_subdir_kind;
- const char *adm_subdir = svn_dirent_join(local_abspath, adm_relpath,
- scratch_pool);
+ const char *adm_subdir;
- SVN_ERR(svn_io_check_path(adm_subdir, &adm_subdir_kind, scratch_pool));
+ svn_pool_clear(iterpool);
+
+ adm_subdir = svn_dirent_join(local_abspath, adm_relpath, iterpool);
+
+ SVN_ERR(svn_io_check_path(adm_subdir, &adm_subdir_kind, iterpool));
if (adm_subdir_kind == svn_node_dir)
{
@@ -673,7 +678,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
if (!moved_upwards || always_check)
{
SVN_ERR(get_old_version(&wc_format, local_abspath,
- scratch_pool));
+ iterpool));
if (wc_format != 0)
break;
}
@@ -697,7 +702,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
SVN_ERR(svn_io_check_resolved_path(local_abspath,
&resolved_kind,
- scratch_pool));
+ iterpool));
if (resolved_kind == svn_node_dir)
{
/* Is this directory recorded in our hash? */
@@ -973,6 +978,7 @@ try_symlink_as_dir:
}
while (strcmp(scan_abspath, local_abspath) != 0);
+ svn_pool_destroy(iterpool);
return SVN_NO_ERROR;
}
diff --git a/subversion/libsvn_wc/wcroot_anchor.c b/subversion/libsvn_wc/wcroot_anchor.c
index 7400aa5c9948..2e675b6a010f 100644
--- a/subversion/libsvn_wc/wcroot_anchor.c
+++ b/subversion/libsvn_wc/wcroot_anchor.c
@@ -183,18 +183,20 @@ svn_wc__get_wcroot(const char **wcroot_abspath,
svn_error_t *
-svn_wc__get_shelves_dir(char **dir,
- svn_wc_context_t *wc_ctx,
- const char *local_abspath,
- apr_pool_t *result_pool,
- apr_pool_t *scratch_pool)
+svn_wc__get_experimental_dir(char **dir,
+ svn_wc_context_t *wc_ctx,
+ const char *local_abspath,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool)
{
const char *wcroot_abspath;
SVN_ERR(svn_wc__get_wcroot(&wcroot_abspath, wc_ctx, local_abspath,
scratch_pool, scratch_pool));
- *dir = svn_dirent_join(wcroot_abspath, ".svn/shelves", result_pool);
-
+ *dir = svn_dirent_join(wcroot_abspath,
+ SVN_WC_ADM_DIR_NAME "/" SVN_WC__ADM_EXPERIMENTAL,
+ result_pool);
+
/* Ensure the directory exists. (Other versions of svn don't create it.) */
SVN_ERR(svn_io_make_dir_recursively(*dir, scratch_pool));