Convert remaining uses of svn_io_open_unique_file2 to other function calls, as appropriate.
* subversion/libsvn_subr/subst.c: (svn_subst_copy_and_translate3, svn_subst_create_translated): switch to svn_stream_open_unique
* subversion/libsvn_subr/io.c: (svn_io_copy_file, svn_io_file_move): switch to svn_io_open_unique_file3. (reown_file): switch param from PATH_APR to just PATH. all the calls were to SVN functions, so we should not be using an APR path. switch to svn_io_open_unique_file3. (io_set_file_perms): pass svn-internal path to reown_file.
* subversion/mod_dav_svn/activity.c: (dav_svn__store_activity): lose a bunch of code in favor of svn_io_write_unique().
* subversion/tests/libsvn_repos/repos-test.c: (authz_get_handle): revamp to use svn_io_write_unique and other svn-style IO functions.
* subversion/svn/util.c: (svn_cl__edit_string_externally): change parameter to FILENAME rather than PREFIX. switch to svn_io_open_uniquely_named.
* subversion/libsvn_wc/props.c: (open_reject_tmp_file, svn_wc__merge_props): switch to svn_io_open_uniquely_named.
* subversion/libsvn_client/externals.c: (relegate_dir_external): switch to svn_io_uniquely_named.
* subversion/libsvn_fs_fs/fs_fs.c: (svn_fs_fs__set_revision_proplist): switch to svn_stream_open_unique (svn_fs_fs__set_uuid): revamp to use svn_io_write_unique
Fix the invocations of svn_io_write_unique(). The docstring states that a directory path should be passed, but all callers were passing a file pathname. This happened to work because of the internal implementation, but broke after some refactoring.
Note: for now, the callers just use svn_path_dirname() to get the directory name of whatever filepath they were about to pass. I assume optimizations could be made later to have the dirpath handy.
Some internal changes were made to io.c as part of an upcoming change around the (soon to be) deprecated svn_io_open_unique_file2() API. These are documented here (insofar as they changed), but not in the API docs at this time. It is these changes which discovered the bad call pattern to svn_io_write_unique().
* subversion/libsvn_subr/io.c: (svn_io_open_unique_file2): the implementation was renamed to ... (svn_io_open_uniquely_named): ... this. the PATH parameter was broken up into a directory path and the filename in that directory. the single pool parameter was split into result and scratch pools. as a temp measure, the old parameter names are now local variables, reconstituted from the new params, in order to minimize change. (svn_io_open_unique_file3): new function similar to svn_stream_open_unique, but returns a plain file. (svn_io_open_unique_file2): new implementation for the original function, which simply calls svn_io_open_uniquely_named() with the appropriate set of parameters. (svn_io_open_unique_file): just param name changes. no functional change. (svn_io_write_unique): simplify, in terms of svn_io_open_unique_file3. (svn_io_file_move): add period to suffix in call to the svn_io_open_unique_file2() function. (svn_io_write_version_file): pass dirpath to svn_io_write_unique