Checkout Tools
  • last updated 1 hour ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Update issue tracker links in comments, from Tigris (issuezilla) to Apache (Jira).

URL fragment identifiers like '#desc5' are left in place, not yet updated.

This is a merge of r1828508 from the 'shelve-checkpoint' branch where I

committed it by mistake.

  1. … 43 more files in changeset.
* subversion/libsvn_repos/log.c

(interesting_merge): Use the new type, following r1731163.

Add missing constructors for new types added in r1731163.

* subversion/include/svn_repos.h,

subversion/libsvn_repos/log.c

(svn_repos_path_change_t,

svn_repos_log_entry_t): Note that the constructor should be used.

(svn_repos_path_change_create,

svn_repos_path_change_dup,

svn_repos_log_entry_create,

svn_repos_log_entry_dup): New.

  1. … 1 more file in changeset.
Deprecate svn_repos_get_logs4.

Small twist here: The ra_local log() implementation needs to expose an

repos_log4-esque API. So, we re-use all the shim code that adapts log5

onto log4 by exposing the latter through a new private API.

* subversion/include/svn_repos.h

(svn_repos_get_logs4): Depricate.

* subversion/include/private/svn_repos_private.h

(svn_repos__get_logs_compat): Declare new private API.

* subversion/libsvn_repos/log.c

(log_entry_receiver_baton_t,

path_change_kind_to_char,

log4_path_change_receiver,

log4_entry_receiver,

svn_repos_get_logs4): Move these log5/log4 shims from here ...

* subversion/libsvn_repos/compat.c

(): ... to this new file.

(svn_repos_get_logs4): Rename this ...

(svn_repos__get_logs_compat): ... to that.

* subversion/libsvn_repos/deprecated.c

(svn_repos_get_logs4): Add trivial implementation.

* subversion/libsvn_ra_local/ra_plugin.c

(svn_ra_local__get_log): Call the new private API instead of the

deprecated one.

  1. … 5 more files in changeset.
Docstring update. No functional change.

* subversion/libsvn_repos/log.c

(do_logs,

location_segment_receiver,

get_paths_history_as_mergeinfo): Update docstrings to cross-reference

the latest API version.

* subversion/libsvn_repos/log.c

(do_logs): Use sizeof(*cur_rev) instead of sizeof(cur_rev) to fix out of

bounds read when sizeof(svn_revnum_t) < sizeof(svn_revnum_t *)

Found by: Coverity <https://scan.coverity.com>

(CID: 1331600)

* subversion/libsvn_repos/log.c

(interesting_merge,

log4_path_change_receiver): Fix API name references in docstrings.

No functional change.

Complete the work on the svn_repos_get_logs4 to svn_repos_get_logs5

migration by publishing the new API.

We don't deprecate the old one until the callers have been updated

and the FS implementations have been finalized so we have the full

picture.

* subversion/include/svn_repos.h

(svn_repos_path_change_t,

svn_repos_path_change_receiver_t,

svn_repos_log_entry_t,

svn_repos_log_entry_receiver_t,

svn_repos_get_logs5): Publish and document the new API. Names and

signatures are taken from the former "__"

definitions in log.c.

* subversion/libsvn_repos/log.c

(svn_repos__path_change_t,

svn_repos__path_change_receiver_t,

svn_repos__log_entry_t,

svn_repos__log_entry_receiver_t): Remove here.

(log_callbacks_t,

fill_log_entry,

interesting_merge_baton_t,

send_log,

handle_merged_revisions): Update type references.

(svn_repos__get_logs5): Renamed to ...

(svn_repos_get_logs5): ... this and updated signature.

(log4_path_change_receiver,

log4_entry_receiver): Update type references.

(svn_repos_get_logs4): Update caller.

  1. … 1 more file in changeset.
* subversion/libsvn_repos/log.c

(detect_changed): Replace obsolete comment. No functional change.

Change some confusing pool usage.

Found by: rhuijben

* subversion/libsvn_repos/log.c

(fs_mergeinfo_changed): Tighten the memory pool usage. The SCRATCH_POOL

would actually live longer than we need it to.

Repos-layer APIs never return incomplete log info.

* subversion/libsvn_repos/log.c

(detect_changed): The copy-from information is always known after

we looked it up.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Switch the last svn_fs_paths_changed2 call to svn_fs_paths_changed3.

* subversion/libsvn_repos/log.c

(fs_mergeinfo_changed): No longer fetch the whole changes list. However,

we need to iterate twice for best total performance

and we need to minimize FS iterator lifetimes.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Finally switch the main log processing to the new FS iterator API.

This finalizes the API work by introducing a repos-layer-specific

path_change_t.

* subversion/libsvn_repos/log.c

(svn_repos__path_change_t): New repos-layer-specific path_change_t.

Keep it identical to the FS one, if feasible.

(svn_repos__path_change_receiver_t): Update signature to use the new type.

(detect_changed): Switch to the iterator-based changes API. No longer

need to convert data here.

(interesting_merge): Update callback.

(path_change_kind_to_char): New utility function.

(log4_path_change_receiver): Update callback. Convert to old data type.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Introduce a repos-layer-specific log_entry type because we won't fill all

fields in svn_log_entry_t anymore.

* subversion/libsvn_repos/log.c

(svn_repos__log_entry_t): Define the new struct type.

(svn_repos__log_entry_receiver_t): The per-revision callback using the new

struct is also repos-layer-specific.

(log_callbacks_t): Update callback type.

(fill_log_entry,

send_log,

handle_merged_revisions): Use the new repos-layer specific struct now.

It no longer needs to be allocated dynamically.

(svn_repos__get_logs5): Update signature to use the new callback type.

(log4_entry_receiver): Translate between new and old log_entry type.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

No longer fill the changed paths hash in the log5 code but only in the

log4 compatibility wrapper.

* subversion/libsvn_repos/log.c

(detect_changed): We no longer collect the CHANGED paths here. That makes

the pool a mere SCRATCH_POOL.

(fill_log_entry): No longer set the CHANGED_PATHS lists in the LOG_ENTRY.

(log_entry_receiver_baton_t,

log4_path_change_receiver,

log4_entry_receiver): Provide full log5-compatible callbacks that gather

the info and forward it to log4-type callbacks.

(svn_repos_get_logs4): Use the new compatibility shim callbacks.

Follow-up to r1730388:

Empty revisions shall report "full revprop access" instead of "no access".

* subversion/libsvn_repos/log.c

(svn_repos_check_revision_access): Re-instantiate special casing for

empty revisions.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Remove the last instance of the discover_changed_paths flag.

* subversion/libsvn_repos/log.c

(fill_log_entry): We can now drop the parameter here because ...

(send_log): ... this one will always set a callback when it needs the data.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Use the new callback to eliminate a changed paths hash scan.

* subversion/libsvn_repos/log.c

(svn_repos__path_change_receiver_t): We need the path info as well.

(detect_changed): Update and fix caller.

(interesting_merge_baton_t,

interesting_merge): New callback implementation. Factored out from ...

(send_log): ... here.

(log4_path_change_receiver): Update signature.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

The discover_changed_paths is now redundant with path_change_receiver being

not NULL.

Remove that flag along the callstack. However, we can't do it completely

and will have two follow-up commits that fix this as well.

* subversion/libsvn_repos/log.c

(send_log,

do_logs,

handle_merged_revisions,

svn_repos__get_logs5): Remove the DISCOVER_CHANGED_PATHS parameter.

(svn_repos_get_logs4): Update caller.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration:

Add a per-changed-path callback.

At the moment, it is entirely redundant and does not use the final data

types, yet.

* subversion/libsvn_repos/log.c

(svn_repos__path_change_receiver_t): Declare the new callback type.

(log_callbacks_t): Add elements for the new callback.

(detect_changed): Invoke the new callback.

(svn_repos__get_logs5): Add new callback to signature and pass it along.

(log4_path_change_receiver): Dummy implementation of the new callback.

(svn_repos_get_logs4): Update caller.

Push the log_callback_t usage further down the call stack. We will soon

need to pass another callback down to detect_changed.

* subversion/libsvn_repos/log.c

(detect_changed,

fill_log_entry): Replace the authz callback parameters with a single

callback structure.

(send_log): Update caller.

Continue work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration.

Remove the support for "prefetched" change lists as it was only ever

effective when running 'log -g' where it prevented fetching the hash

a second time. With the new log API, this is much less of a performance

issue, plus we have the option of an early out by not even reading all

entries once we found an "interesting" one.

* subversion/libsvn_repos/log.c

(detect_changed,

fs_mergeinfo_changed): Drop the PREFETCHED_CHANGES parameter and simply

always fetch the changes.

(get_combined_mergeinfo_changes,

fill_log_entry,

send_log): Remove the PREFETCHED_CHANGES pass-through parameter.

(do_logs): Remove CHANGES re-use logic.

(svn_repos__get_logs5): Update caller.

Continue preparations for updating the repos layer log API.

We introduce a utility struct that combines all callbacks we use.

This will reduce the code churn when we add Yet Another Callback.

* subversion/libsvn_repos/log.c

(log_callbacks_t): Declare the new internal struct.

(send_log,

do_logs,

handle_merged_revisions,

do_logs): Replace individual callback funtions & batons in the

signatures with a single callback struct instance.

(svn_repos__get_logs5): Intialize the callback struct.

Begin work on the svn_repos_get_logs4 to svn_repos_get_logs5 migration.

As a first step, we introduce what will become svn_repos_get_logs5 as

a static function and implement svn_repos_get_logs4 as a wrapper.

* subversion/libsvn_repos/log.c

(svn_repos__get_logs5): New function with the same basic code as

svn_repos_get_logs4 had but the POOL is now

a SCRATCH_POOL.

(svn_repos_get_logs4): This is now a mere wrapper around the prior.

* subversion/libsvn_repos/log.c

(svn_repos_check_revision_access): Switch to using the new

svn_fs_paths_changed3 API.

* subversion/libsvn_repos/log.c

(svn_repos_check_revision_access): This SUBPOOL is actually a ITERPOOL.

Introduce the SVN__STATIC_STRING macro to simplify the definition of

static svn_string_t instances.

* subversion/include/private/svn_string_private.h

(SVN__STATIC_STRING): Define new macro.

* subversion/libsvn_repos/log.c

(fill_log_entry): Use the new macro.

* subversion/libsvn_wc/props.c

(svn_wc_canonicalize_svn_prop): Ditto.

  1. … 2 more files in changeset.
Speed up revprop access in svn_repos_get_logs4 by using the latest FS API.

* subversion/libsvn_repos/log.c

(fill_log_entry): Read revprops from the FS cache if we can.

(svn_repos_get_logs4): Refresh the revprops only once, at the start of

the operation. This is the only public function

that, indirectly, calls the above. Therefore, we

still fulfill the visibility guarantees for

revprop changes.

* subversion/libsvn_fs/fs-loader.c

(svn_fs_lock_target_create): Take the size to allocate from the variable

rather than its type. That type is specified

in the same line anyway.

* subversion/libsvn_repos/log.c

(store_search): Same.

* subversion/libsvn_subr/x509parse.c

(x509_get_ext): Same.

  1. … 2 more files in changeset.
When accessing an APR hash with a non-string key, take the key size from

the key variable instead of its type. This makes the code more robust in

case we want to change the key type in the future.

* subversion/libsvn_client/ra.c

(repos_locations): Take the key size from the key variable.

* subversion/libsvn_repos/log.c

(do_logs): Same.

* subversion/mod_dav_svn/repos.c

(parse_querystring): Same.

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

(file_rev_handler,

verify_locations,

set_expected): Same.

* tools/dev/fsfs-access-map.c

(open_file): Same.

  1. … 4 more files in changeset.