Checkout Tools
  • last updated 7 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Improve backward compatibility for svn_delta_path_driver2().

This ensures the input array is not modified, and changes the behaviour to

be less surprising.

* subversion/include/svn_delta.h,

subversion/libsvn_delta/deprecated.c

(svn_delta_path_driver2): Add back slash prefixes if any, rather than the

first, of the inputs had one. Duplicate the array if modifying it.

  1. … 1 more file in changeset.
In the updated delta editor path driver, ensure paths are relpaths.

This also fixes a bug with '/'-prefixed paths in svn_delta_path_driver2(). A

path given as the string "/" was handled as a regular path (first open the

editor root, then call the callback passing it the root parent-dir-baton)

rather than as a root path.

* subversion/include/svn_delta.h

(svn_delta_path_driver_cb_func2_t,

svn_delta_path_driver3,

svn_delta_path_driver_step): Declare that paths are relpaths.

(svn_delta_path_driver2): Document that a slash prefix is allowed.

* subversion/libsvn_delta/deprecated.c

(path_driver_2_to_3_baton_t,

path_driver_2_to_3_func,

svn_delta_path_driver2): Implement backward compatibility for a slash

prefix.

* subversion/libsvn_delta/path_driver.c

(svn_delta_path_driver3): Rename variables to 'relpath', for clarity.

(svn_delta_path_driver_step): Assert the path is a relpath, remove support

for a slash prefix, and rename variables.

  1. … 2 more files in changeset.
Make the editor path driver callback a little easier to use.

Add 'editor' and 'edit_baton' parameters to the path driver callback. All

but trivial callback implementations need these, and they otherwise had to

be passed through the callback baton, which was straightforward but more

trouble than it need be.

* subversion/include/svn_delta.h

(svn_delta_path_driver_cb_func2_t,

svn_delta_path_driver3): New.

* subversion/libsvn_delta/path_driver.c

(svn_delta_path_driver3): Rename from 'svn_delta_path_driver2'.

(svn_delta_path_driver_state_t,

svn_delta_path_driver_start): Change the callback function type.

(svn_delta_path_driver_step): Pass the extra parameters.

* subversion/libsvn_delta/deprecated.c

(path_driver_2_to_3_baton_t,

path_driver_2_to_3_func,

svn_delta_path_driver2): New.

* subversion/libsvn_client/shelf.c

(path_driver_cb_func): Take 'editor' and 'edit_baton' as direct parameters.

(path_driver_cb_baton_t,

svn_client__shelf_replay): Remove them from the path driver baton.

  1. … 3 more files in changeset.
Extend the svn_delta_path_driver2 (rev'ed for 1.8) API such that

it becomes more suitable for existing callers of the deprecated

svn_delta_path_driver. Making the rev'ed API optionally sort the

path list will be enough. Update all callers to not use the

deprecated API.

* subversion/include/svn_delta.h

(svn_delta_path_driver2): add sort_paths parameter

* subversion/libsvn_delta/path_driver.c

(svn_delta_path_driver2): adapt implementation

* subversion/libsvn_delta/deprecated.c

(svn_delta_path_driver): simplify

* subversion/libsvn_client/add.c

(mkdir_urls): use rev'ed API

* subversion/libsvn_client/commit_util.c

(svn_client__do_commit): ditto

* subversion/libsvn_client/copy.c

(repos_to_repos_copy): same here ...

* subversion/libsvn_client/delete.c

(single_repos_delete): and here ...

* subversion/libsvn_delta/compat.c

(drive_changes): here ...

* subversion/libsvn_repos/replay.c

(svn_repos_replay2): and finally here

  1. … 8 more files in changeset.
* notes/ev2-callbacks-template.c

* notes/directory-index/dirindex.py

* notes/directory-index/logimport.py

* subversion/libsvn_delta/deprecated.c

* subversion/libsvn_ra/editor.c

* subversion/libsvn_fs/editor.c

* subversion/include/private/svn_delta_private.h

* tools/dev/histogram.py

* tools/dev/gdb-py/svndbg/printers.py

* tools/dev/gdb-py/svndbg/__init__.py

* tools/dev/sbox-ospath.py

* tools/client-side/mergeinfo-sanitizer.py

* tools/server-side/svnpubsub/commit-hook.py

* tools/server-side/svnpubsub/testserver.py

* tools/server-side/svnpubsub/svnwcsub.py

* tools/server-side/svnpubsub/daemonize.py

* tools/server-side/svnpubsub/watcher.py

* tools/server-side/svnpubsub/svntweet.py

* tools/server-side/svnpubsub/svnpubsub/client.py

* tools/server-side/svnpubsub/svnpubsub/__init__.py

* tools/server-side/svnpubsub/svnpubsub/server.py

* tools/server-side/svnpredumpfilter.py

(svn:eol-style): Set to native for *.c, *.h, *.py, *.java.

  1. … 21 more files in changeset.
Add a new revision of svn_delta_path_driver that omits the (unused)

REVISION parameter, and does not sort the input paths. The current

implementation would actually alter the PATHS array(!). The revised

API allows the caller to create a specialized ordering of paths.

* subversion/include/svn_delta.h:

(svn_delta_path_driver2): new declaration as replace for ...

(svn_delta_path_driver): ... this.

* subversion/libsvn_delta/deprecated.c:

(...): new file

(svn_delta_path_driver): backwards-compat implementation

* subversion/libsvn_delta/path_driver.c:

(open_dir): removed REVISION parameter and just always pass

SVN_INVALID_REVNUM to the open_directory() delta callback.

(svn_delta_path_driver): renamed to ...

(svn_delta_path_driver2): ... this. REVISION param dropped. sorting

of input paths removed.

  1. … 2 more files in changeset.