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

Changeset 1769485 is being indexed.

Change the svn_*_list APIs to use NULL as the "don't filter by pattern"

parameter instead of an empty pattern list.

Suggested by: Patrick Steinhardt (patrick.steinhardt at

* subversion/include/svn_repos.h

(svn_repos_list): Document the new PATTERN options behavior.

* subversion/libsvn_repos/list.c

(matches_any): Implement the new behavior.

(svn_repos_list): Empty lists will almost always be created by dumb

scripts. It's probably a good idea to explicitly

not waste any resources in the degenerate case.

* subversion/include/svn_ra.h

(svn_ra_list): Document the new PATTERN options behavior.

* subversion/libsvn_ra_svn/protocol

(3.1.1. Main Command Set): The patterns list in the list command is

now optional.

* subversion/libsvn_subr/log.c

(svn_log__list): Make the logging cope with NULL pattern lists.

* subversion/svnserve/serve.c

(list): Receive NULL for PATTERNS, if no list was received.

* subversion/libsvn_ra_svn/client.c

(ra_svn_list): Omit the pattern list entirely, if patterns is NULL.

* subversion/include/svn_client.h

(svn_client_list4): Document the new PATTERN options behavior.

(svn_client_list3): Update docstring.

* subversion/libsvn_client/deprecated.c

(svn_client_list3): Update implementation.

* subversion/libsvn_client/list.c

(match_patterns): Implement the new behavior.

(list_internal): Update docstring.

* subversion/svn/list-cmd.c

(svn_cl__list): If no patterns were specified, pass NULL to the API.

* subversion/svnbench/null-list-cmd.c

(svn_cl__null_list): Same.

  1. … 11 more files in changeset.
Fix 'svn ls' with authz broken by the introduction of svn_repos_list.

* subversion/libsvn_repos/list.c

(do_list): Actually check against the current path instead of the base.

Make ra_local tests pass again:

Handle edge and error cases for list the same as in the client-only code.

* subversion/libsvn_repos/list.c

(svn_repos_list): Allow 'list' for file nodes and use the same error

code for nodes that are neither file nor directory.

Finalize the svn_repos_list interface: Name scratch pools explicitly.

* subversion/include/svn_repos.h


svn_repos_list): The pools given here are pure SCRATCH_POOLs.

* subversion/libsvn_repos/list.c




svn_repos_list): Same.

  1. … 1 more file in changeset.
Make the new svn_repos_list easier to use with typical client requests.

Instead of a single pattern, accept an array of alternative patterns of

which at least one must match if any patterns are given. Sort the output

by path to make it match the client-side implementation's output order.

* subversion/include/svn_repos.h

(svn_repos_list): We now support multiple glob patterns and sort the


* subversion/libsvn_repos/list.c

(matches_any): New utility function for matching against an array

instead of a single pattern.

(report_dirent): For efficiency reasons, we now filter early before

calling this reporter function.


compare_filtered_dirent): New filtering and sorting support.

(do_list): Support multiple PATTERNS. Filter and sort the data before

processing it further.

(svn_repos_list): Update signature, filtering and passing of parameters.

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

(test_list): Adapt test case to interface change.

  1. … 2 more files in changeset.
Fix a copy-n-pasto in the new svn_repos_list code.

Found by: danielsh

* subversion/libsvn_repos/list.c

(svn_repos_list): The DEPTH parameter is relevant for the top-level dir.

Introduce a "directory list" operation at the repos layer. This is the

first step towards an efficient implementation of 'svn list -r'.

The function is straight-forward with support for operation depth and

authz. One important use-case is "find files". To support this with

minimal system load, the function allows to specify a glob pattern for

the file name and has an option to only report path and node type.

* subversion/include/svn_repos.h


svn_repos_list): The new API.

* subversion/libsvn_repos/list.c

(*): New file implementing the new API. Noteworthy:

(fill_dirent): Factored out from ...

(svn_repos_stat): ... this, which has been moved here from repos.c

* subversion/libsvn_repos/repos.c

(svn_repos_stat): Move from here to list.c due to shared code.

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

(test_list): Simple test-case for the new function.

(test_funcs): Register new test.

  1. … 3 more files in changeset.