Import subversion-1.8.1 into vendor staging area.

This commit is contained in:
Peter Wemm 2013-07-28 05:04:41 +00:00
parent fec88c40a7
commit 97551b2898
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/vendor/subversion/dist/; revision=253728
svn path=/vendor/subversion/subversion-1.8.1/; revision=253729; tag=vendor/subversion/subversion-1.8.1
82 changed files with 2428 additions and 1019 deletions

108
CHANGES
View File

@ -1,3 +1,91 @@
Version 1.8.1
(23 July 2013, from /branches/1.8.x)
http://svn.apache.org/repos/asf/subversion/tags/1.8.1
User-visible changes:
- Client- and server-side bugfixes:
* translation updates for German and Simplified Chinese
* improve sqlite error message output (r1497804)
* support platforms lacking mmap (r1498136)
* allow configuration files to start with UTF-8 BOM (r1499100 et al)
* don't fail on UTF-8 data when encoding conversion not available (r1503009)
* improve error messages when encoding conversion fails (r1503010)
- Client-side bugfixes:
* merge: rename 'automatic merge' to 'complete merge' (r1491432)
* mergeinfo: reduce network usage for '--show-revs' (r1492005)
* ra_serf: improve http status handling (r1495104)
* merge: avoid unneeded ra session (r1493475)
* merge: reduce network usage (r1478987)
* merge: remove duplicated ancestry check (r1493424, r1495597)
* ra_serf: fix 'Accept-Encoding' header for IIS interoperability (r1497551)
* svn status: improve documentation for lock columns (r1497318, r1497319)
* ra_serf: fix support for 'get-file-revs-reversed' capability (r1498456)
* log: reduce network usage on repository roots (r1496957)
* diff: avoid temporary files when calling external diff (issue #4382)
* upgrade: fix notification of 1.7.x working copies (r1493703, r1494171)
* fix crash during tree conflict resolution (issue #4388)
* interactive file merge: add two additional choices (r1491816, r1494089)
* diff: use local style paths in error messages (r1500680)
* resolve: improve the interactive conflict resolution menu (r1491739 et al)
* switch: use local style path in error message (r1500074)
* ra_serf: improve error output when receiving invalid XML (r1498851)
* svn cleanup: explain what the command does in help output (r1497310)
* blame: error on -r M:N where M>N unless server supports (r1498449 et al)
* gpg-agent auth: don't try to use agent when unavailable (r1500762 et al)
* gpg-agent auth: don't require GPG_TTY or TERM env vars (r1500801)
* update: fix some tree conflicts not triggering resolver (r1491868 et al)
* commit: remove stale entries from wc lock table when deleting (r1491756)
* merge: fix --record-only erroring out on renamed path (issue #4387)
* svnmucc: fix 'make install' symlink to work when DESTDIR is set (r1501072)
* wc: fix crash when target is symlink to a working copy root (issue #4383)
* ra_serf: change "internal malfunction" errors to normal errors (r1502577)
* ra_serf: handle proxies not supporting chunked requests (r1502401 et al)
- Server-side bugfixes:
* fsfs: resolve endless loop problem when repos/db/uuid has \r\n (r1492145)
* fsfs: remove revision property buffer limit (r1491770)
* mod_dav_svn: better status codes for anonymous user errors (r1495918)
* mod_dav_svn: better status codes for commit failures (r1490684)
* fix performance regression in 'svn log' against root (r1494913)
* allow deleting non-user-visible 'svn:' properties (r1495432)
* fsfs: fix crash on strict-alignment architectures (r1495806, r1495985)
* svnadmin upgrade: fix error of non-sharded fsfs repositories (r1494287)
* svnadmin create: deny '--fs-type=fsfs --compatible-version=1.0' (r1494223)
* svnadmin upgrade: fix data loss when cancelling in last stage (r1494298)
* mod_dav_svn: fix incorrect path canonicalization (r1503528)
- Other tool improvements and bugfixes:
* fsfs-stats (tool): resolve segfault when passing invalid path (r1492164)
* svn-bench: fix help output (r1493951)
* svnpubsub: add version header to server (r1491707)
Developer-visible changes
- General:
* ra_serf: fix some test runner issues on Windows (r1490679)
* fix two issues in reverse svn_ra_get_file_revs() (r1492148, et al)
* handle --compatible-version=1.8 in the C tests (r1494342)
* improve clang compatibility (r1480080 et al)
* use proper cancel baton when handling conflicts (r1495850)
* fs: BDB: provide proper error value from BDB (r1495428)
* ra_serf: tweak connection failed error value (r1496132, et al)
* svn_client_log5: resolve possible segfault (r1496110)
* fix metadata_only move to work when target is unversioned node (r1498564)
* ra_svn: fix segfault with a NULL commit message (r1498550, r1499727)
* Ev2: correctly initialize node kind in shims' change table (r1501058)
* Ev2: fix copyfrom URL construction in shims (r1500226)
* fs: improve test against newlines in filenames (r1498483 et al)
* make building with BDB 6 an opt-in feature (r1499438)
* sqlite: allow placing amalgamation in build dir (r1499034, r1500175)
* ra_svn: make sessions usable after log callback early out (r1503554)
- Bindings:
* swig-rb: fix tests with out-of-tree-builds (r1492295)
* javahl: fix encoding of error messages produced by javahl (r1492264)
* swig-pl: silence compiler warnings (r1487094)
* swig-pl: improve documentation (r1488693, r1490721, r1500904)
Version 1.8.0
(18 Jun 2013, from /branches/1.8.x)
http://svn.apache.org/repos/asf/subversion/tags/1.8.0
@ -99,7 +187,6 @@ http://svn.apache.org/repos/asf/subversion/tags/1.8.0
* support ipv6 in URLs (e.g. http://[::1]/svn/repos) (r1454047)
* conflict resolver now iterates paths in a sorted order (r1461820)
* mod_dav_svn does keyword expansion with 'kw=1' query arg (r1466055)
* add support for custom keyword definitions (issue #890)
- Minor new features and improvements (server-side):
* improve performance of config file parsing (r1344347 et al)
@ -339,6 +426,25 @@ http://svn.apache.org/repos/asf/subversion/tags/1.8.0
* fix some reference counting bugs in swig-py bindings (r1464899, r1466524)
Version 1.7.11
(23 Jul 2013, from /branches/1.7.x)
http://svn.apache.org/repos/asf/subversion/tags/1.7.11
User-visible changes:
- General
* translation updates for Simplified Chinese
- Server-side bugfixes:
* mod_dav_svn: fix incorrect path canonicalization (r1503528)
- Other tool improvements and bugfixes:
* fix argument processing in contrib hook scripts (r1485350)
Developer-visible changes:
- Bindings:
* javahl: fix bug in error constructing code (r1405922)
Version 1.7.10
(30 May 2013, from /branches/1.7.x)
http://svn.apache.org/repos/asf/subversion/tags/1.7.10

View File

@ -903,5 +903,5 @@ INSTALL_EXTRA_TOOLS=\
test -n "$$SVN_SVNMUCC_IS_SVNSYITF" && \
ln -sf svnmucc$(EXEEXT) $(DESTDIR)$(bindir)/svnsyitf$(EXEEXT); \
if test "$(DESTDIR)$(bindir)" != "$(DESTDIR)$(toolsdir)"; then \
ln -sf $(DESTDIR)$(bindir)/svnmucc$(EXEEXT) $(DESTDIR)$(toolsdir)/svnmucc$(EXEEXT); \
ln -sf $(bindir)/svnmucc$(EXEEXT) $(DESTDIR)$(toolsdir)/svnmucc$(EXEEXT); \
fi

View File

@ -1985,7 +1985,7 @@ subversion/libsvn_client/delete.lo: subversion/libsvn_client/delete.c subversion
subversion/libsvn_client/deprecated.lo: subversion/libsvn_client/deprecated.c subversion/include/private/svn_client_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_tree.h subversion/include/private/svn_editor.h subversion/include/private/svn_magic.h subversion/include/private/svn_opt_private.h subversion/include/private/svn_wc_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_compat.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_wc.h subversion/libsvn_client/client.h subversion/libsvn_client/mergeinfo.h subversion/svn_private_config.h
subversion/libsvn_client/diff.lo: subversion/libsvn_client/diff.c subversion/include/private/svn_client_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_private.h subversion/include/private/svn_diff_tree.h subversion/include/private/svn_editor.h subversion/include/private/svn_magic.h subversion/include/private/svn_subr_private.h subversion/include/private/svn_wc_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_wc.h subversion/libsvn_client/client.h subversion/svn_private_config.h
subversion/libsvn_client/diff.lo: subversion/libsvn_client/diff.c subversion/include/private/svn_client_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_private.h subversion/include/private/svn_diff_tree.h subversion/include/private/svn_editor.h subversion/include/private/svn_io_private.h subversion/include/private/svn_magic.h subversion/include/private/svn_subr_private.h subversion/include/private/svn_wc_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_wc.h subversion/libsvn_client/client.h subversion/svn_private_config.h
subversion/libsvn_client/diff_local.lo: subversion/libsvn_client/diff_local.c subversion/include/private/svn_client_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_tree.h subversion/include/private/svn_editor.h subversion/include/private/svn_magic.h subversion/include/private/svn_wc_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_sorts.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_types.h subversion/include/svn_wc.h subversion/libsvn_client/client.h subversion/svn_private_config.h
@ -2703,7 +2703,7 @@ subversion/svnadmin/svnadmin.lo: subversion/svnadmin/svnadmin.c subversion/inclu
subversion/svndumpfilter/svndumpfilter.lo: subversion/svndumpfilter/svndumpfilter.c subversion/include/private/svn_cmdline_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_mergeinfo_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_cmdline.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_repos.h subversion/include/svn_sorts.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_version.h subversion/svn_private_config.h
subversion/svnlook/svnlook.lo: subversion/svnlook/svnlook.c subversion/include/private/svn_cmdline_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_private.h subversion/include/private/svn_fspath.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_cmdline.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_repos.h subversion/include/svn_sorts.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_time.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_version.h subversion/include/svn_xml.h subversion/svn_private_config.h
subversion/svnlook/svnlook.lo: subversion/svnlook/svnlook.c subversion/include/private/svn_cmdline_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_diff_private.h subversion/include/private/svn_fspath.h subversion/include/private/svn_io_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_cmdline.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_repos.h subversion/include/svn_sorts.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_time.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_version.h subversion/include/svn_xml.h subversion/svn_private_config.h
subversion/svnmucc/svnmucc.lo: subversion/svnmucc/svnmucc.c subversion/include/private/svn_cmdline_private.h subversion/include/private/svn_debug.h subversion/include/private/svn_editor.h subversion/include/private/svn_ra_private.h subversion/include/private/svn_string_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_cmdline.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_ra.h subversion/include/svn_string.h subversion/include/svn_subst.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/include/svn_version.h subversion/include/svn_wc.h subversion/svn_private_config.h
@ -2749,7 +2749,7 @@ subversion/tests/libsvn_diff/diff-diff3-test.lo: subversion/tests/libsvn_diff/di
subversion/tests/libsvn_diff/parse-diff-test.lo: subversion/tests/libsvn_diff/parse-diff-test.c subversion/include/private/svn_debug.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_io.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/tests/svn_test.h
subversion/tests/libsvn_fs/fs-test.lo: subversion/tests/libsvn_fs/fs-test.c subversion/include/private/svn_debug.h subversion/include/private/svn_editor.h subversion/include/private/svn_fs_private.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_time.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/libsvn_delta/delta.h subversion/tests/svn_test.h subversion/tests/svn_test_fs.h
subversion/tests/libsvn_fs/fs-test.lo: subversion/tests/libsvn_fs/fs-test.c subversion/include/private/svn_debug.h subversion/include/private/svn_editor.h subversion/include/private/svn_fs_private.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_props.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_time.h subversion/include/svn_types.h subversion/include/svn_version.h subversion/libsvn_delta/delta.h subversion/tests/svn_test.h subversion/tests/svn_test_fs.h
subversion/tests/libsvn_fs/locks-test.lo: subversion/tests/libsvn_fs/locks-test.c subversion/include/private/svn_debug.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/tests/svn_test.h subversion/tests/svn_test_fs.h
@ -2849,7 +2849,7 @@ subversion/tests/libsvn_wc/wc-queries-test.lo: subversion/tests/libsvn_wc/wc-que
subversion/tests/libsvn_wc/wc-test.lo: subversion/tests/libsvn_wc/wc-test.c subversion/include/private/svn_debug.h subversion/include/private/svn_dep_compat.h subversion/include/private/svn_diff_tree.h subversion/include/private/svn_skel.h subversion/include/private/svn_sqlite.h subversion/include/private/svn_token.h subversion/include/private/svn_wc_private.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_client.h subversion/include/svn_config.h subversion/include/svn_delta.h subversion/include/svn_diff.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_ra.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_wc.h subversion/libsvn_wc/wc.h subversion/libsvn_wc/wc_db.h subversion/libsvn_wc/wc_db_private.h subversion/svn_private_config.h subversion/tests/libsvn_wc/utils.h subversion/tests/svn_test.h
subversion/tests/svn_test_fs.lo: subversion/tests/svn_test_fs.c subversion/include/private/svn_debug.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/tests/svn_test.h subversion/tests/svn_test_fs.h
subversion/tests/svn_test_fs.lo: subversion/tests/svn_test_fs.c subversion/include/private/svn_debug.h subversion/include/svn_checksum.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_fs.h subversion/include/svn_hash.h subversion/include/svn_io.h subversion/include/svn_mergeinfo.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_repos.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/include/svn_utf.h subversion/tests/svn_test.h subversion/tests/svn_test_fs.h
subversion/tests/svn_test_main.lo: subversion/tests/svn_test_main.c subversion/include/private/svn_cmdline_private.h subversion/include/private/svn_debug.h subversion/include/svn_auth.h subversion/include/svn_checksum.h subversion/include/svn_cmdline.h subversion/include/svn_config.h subversion/include/svn_ctype.h subversion/include/svn_delta.h subversion/include/svn_dirent_uri.h subversion/include/svn_error.h subversion/include/svn_error_codes.h subversion/include/svn_io.h subversion/include/svn_opt.h subversion/include/svn_path.h subversion/include/svn_pools.h subversion/include/svn_string.h subversion/include/svn_types.h subversion/svn_private_config.h subversion/tests/svn_test.h

508
configure vendored
View File

@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for subversion 1.8.0.
# Generated by GNU Autoconf 2.69 for subversion 1.8.1.
#
# Report bugs to <http://subversion.apache.org/>.
#
@ -590,8 +590,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='subversion'
PACKAGE_TARNAME='subversion'
PACKAGE_VERSION='1.8.0'
PACKAGE_STRING='subversion 1.8.0'
PACKAGE_VERSION='1.8.1'
PACKAGE_STRING='subversion 1.8.1'
PACKAGE_BUGREPORT='http://subversion.apache.org/'
PACKAGE_URL=''
@ -872,6 +872,7 @@ with_trang
with_doxygen
with_expat
with_berkeley_db
enable_bdb6
with_sasl
enable_keychain
with_gpg_agent
@ -1455,7 +1456,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures subversion 1.8.0 to adapt to many kinds of systems.
\`configure' configures subversion 1.8.1 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@ -1521,7 +1522,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of subversion 1.8.0:";;
short | recursive ) echo "Configuration of subversion 1.8.1:";;
esac
cat <<\_ACEOF
@ -1547,6 +1548,10 @@ Optional Features:
testing prior to installation on some platforms. It
does not work on some platforms (Darwin, OpenBSD,
...).
--enable-bdb6 Allow building against BDB 6+. See
--with-berkeley-db for specifying the location of
the Berkeley DB installation. Using BDB 6 will fail
if this option is not used.
--disable-keychain Disable use of Mac OS KeyChain for auth credentials
--enable-ev2-impl Use Ev2 implementations, where available
[EXPERIMENTAL]
@ -1609,9 +1614,9 @@ Optional Packages:
Specify location of Expat
--with-berkeley-db[=HEADER:INCLUDES:LIB_SEARCH_DIRS:LIBS]
The Subversion Berkeley DB based filesystem library
requires Berkeley DB $db_version or newer. If you
specify `--without-berkeley-db', that library will
not be built. If you omit the argument of this
requires Berkeley DB $db_version or $db_alt_version.
If you specify `--without-berkeley-db', that library
will not be built. If you omit the argument of this
option completely, the configure script will use
Berkeley DB used by APR-UTIL.
--with-sasl=PATH Compile with libsasl2 in PATH
@ -1731,7 +1736,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
subversion configure 1.8.0
subversion configure 1.8.1
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@ -2275,7 +2280,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by subversion $as_me 1.8.0, which was
It was created by subversion $as_me 1.8.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@ -2655,8 +2660,8 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
{ $as_echo "$as_me:${as_lineno-$LINENO}: Configuring Subversion 1.8.0" >&5
$as_echo "$as_me: Configuring Subversion 1.8.0" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: Configuring Subversion 1.8.1" >&5
$as_echo "$as_me: Configuring Subversion 1.8.1" >&6;}
abs_srcdir="`cd $srcdir && pwd`"
@ -3612,6 +3617,44 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
_svn_xxflags__save="$CFLAGS"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC accepts -Werror=unknown-warning-option" >&5
$as_echo_n "checking if $CC accepts -Werror=unknown-warning-option... " >&6; }
CFLAGS="-Werror=unknown-warning-option $CFLAGS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
CFLAGS="$_svn_xxflags__save"
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
# Look for a C++ compiler (before anything can set CXXFLAGS)
CXXMAINTAINERFLAGS="$CXXUSERFLAGS"
CXXUSERFLAGS="$CXXFLAGS"
@ -3921,6 +3964,44 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
_svn_xxflags__save="$CXXFLAGS"
ac_ext=cpp
ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CXX accepts -Werror=unknown-warning-option" >&5
$as_echo_n "checking if $CXX accepts -Werror=unknown-warning-option... " >&6; }
CXXFLAGS="-Werror=unknown-warning-option $CXXFLAGS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
_ACEOF
if ac_fn_cxx_try_compile "$LINENO"; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
CXXFLAGS="$_svn_xxflags__save"
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
# Look for a C pre-processor
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
@ -6161,6 +6242,10 @@ $as_echo "$as_me: WARNING: no suitable sqlite found in $sqlite_dir" >&2;}
echo "unpack the archive using unzip and rename the resulting"
echo "directory to:"
echo "$abs_srcdir/sqlite-amalgamation"
if test x"$abs_srcdir" != x"$abs_builddir"; then
echo "or to:"
echo "$abs_builddir/sqlite-amalgamation"
fi
echo ""
as_fn_error $? "Subversion requires SQLite" "$LINENO" 5
@ -6461,6 +6546,299 @@ rm -f conftest*
if test -z "$svn_lib_sqlite"; then
sqlite_amalg="$abs_builddir/sqlite-amalgamation/sqlite3.c"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking sqlite amalgamation" >&5
$as_echo_n "checking sqlite amalgamation... " >&6; }
if test ! -e $sqlite_amalg; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking sqlite amalgamation file version" >&5
$as_echo_n "checking sqlite amalgamation file version... " >&6; }
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include "$sqlite_amalg"
#if SQLITE_VERSION_NUMBER >= $sqlite_min_ver_num
SQLITE_VERSION_OKAY
#endif
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
$EGREP "SQLITE_VERSION_OKAY" >/dev/null 2>&1; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: amalgamation found and is okay" >&5
$as_echo "amalgamation found and is okay" >&6; }
case $host_os in
beos* | mingw* | pw32* | cegcc* | cygwin*)
svn_sqlite_dso_ldflags=
;;
darwin*)
# if libdl is installed we need to link against it
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
$as_echo_n "checking for dlopen in -ldl... " >&6; }
if ${ac_cv_lib_dl_dlopen+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char dlopen ();
int
main ()
{
return dlopen ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_dl_dlopen=yes
else
ac_cv_lib_dl_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
lt_cv_dlopen="dlopen" svn_sqlite_dso_ldflags="-ldl"
else
svn_sqlite_dso_ldflags=
fi
;;
*)
ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
if test "x$ac_cv_func_shl_load" = xyes; then :
svn_sqlite_dso_ldflags=
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
$as_echo_n "checking for shl_load in -ldld... " >&6; }
if ${ac_cv_lib_dld_shl_load+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char shl_load ();
int
main ()
{
return shl_load ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_dld_shl_load=yes
else
ac_cv_lib_dld_shl_load=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
svn_sqlite_dso_ldflags="-ldld"
else
ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
if test "x$ac_cv_func_dlopen" = xyes; then :
svn_sqlite_dso_ldflags=
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
$as_echo_n "checking for dlopen in -ldl... " >&6; }
if ${ac_cv_lib_dl_dlopen+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char dlopen ();
int
main ()
{
return dlopen ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_dl_dlopen=yes
else
ac_cv_lib_dl_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
svn_sqlite_dso_ldflags="-ldl"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
$as_echo_n "checking for dlopen in -lsvld... " >&6; }
if ${ac_cv_lib_svld_dlopen+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lsvld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char dlopen ();
int
main ()
{
return dlopen ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_svld_dlopen=yes
else
ac_cv_lib_svld_dlopen=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
svn_sqlite_dso_ldflags="-lsvld"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
$as_echo_n "checking for dld_link in -ldld... " >&6; }
if ${ac_cv_lib_dld_dld_link+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldld $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char dld_link ();
int
main ()
{
return dld_link ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_dld_dld_link=yes
else
ac_cv_lib_dld_dld_link=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
svn_sqlite_dso_ldflags="-ldld"
fi
fi
fi
fi
fi
fi
;;
esac
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking additional libraries for sqlite" >&5
$as_echo_n "checking additional libraries for sqlite... " >&6; }
if test -n "$svn_sqlite_dso_ldflags"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${svn_sqlite_dso_ldflags}" >&5
$as_echo "${svn_sqlite_dso_ldflags}" >&6; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
$as_echo "none" >&6; }
fi
$as_echo "#define SVN_SQLITE_INLINE 1" >>confdefs.h
SVN_SQLITE_INCLUDES="-I`dirname $sqlite_amalg`"
if test -n "$svn_sqlite_dso_ldflags"; then
SVN_SQLITE_LIBS="$svn_sqlite_dso_ldflags -lpthread"
else
SVN_SQLITE_LIBS="-lpthread"
fi
svn_lib_sqlite="yes"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported amalgamation SQLite version" >&5
$as_echo "unsupported amalgamation SQLite version" >&6; }
fi
rm -f conftest*
fi
fi
if test -z "$svn_lib_sqlite"; then
if test -z ""; then
sqlite_dir=""
sqlite_include="sqlite3.h"
@ -6633,6 +7011,10 @@ $as_echo "no" >&6; }
echo "unpack the archive using unzip and rename the resulting"
echo "directory to:"
echo "$abs_srcdir/sqlite-amalgamation"
if test x"$abs_srcdir" != x"$abs_builddir"; then
echo "or to:"
echo "$abs_builddir/sqlite-amalgamation"
fi
echo ""
as_fn_error $? "Subversion requires SQLite" "$LINENO" 5
@ -17537,6 +17919,7 @@ powerpc-apple-darwin*)
SVN_FS_WANT_DB_PATCH=14
;;
esac
db_alt_version="5.x"
# Look for libdb4.so first:
db_version=$SVN_FS_WANT_DB_MAJOR.$SVN_FS_WANT_DB_MINOR.$SVN_FS_WANT_DB_PATCH
@ -17624,6 +18007,14 @@ fi
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for availability of Berkeley DB" >&5
$as_echo_n "checking for availability of Berkeley DB... " >&6; }
# Check whether --enable-bdb6 was given.
if test "${enable_bdb6+set}" = set; then :
enableval=$enable_bdb6; enable_bdb6=$enableval
else
enable_bdb6=unspecified
fi
svn_lib_berkeley_db_try_save_cppflags="$CPPFLAGS"
svn_lib_berkeley_db_try_save_libs="$LIBS"
@ -17631,6 +18022,7 @@ $as_echo_n "checking for availability of Berkeley DB... " >&6; }
svn_check_berkeley_db_major=$SVN_FS_WANT_DB_MAJOR
svn_check_berkeley_db_minor=$SVN_FS_WANT_DB_MINOR
svn_check_berkeley_db_patch=$SVN_FS_WANT_DB_PATCH
enable_bdb6=$enable_bdb6
if test -z "$SVN_DB_LIBS"; then
# We pass --dbm-libs here since Debian has modified apu-config not
@ -17673,6 +18065,7 @@ else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <string.h>
#include <stdlib.h>
$svn_db_header
@ -17688,6 +18081,12 @@ int main ()
|| patch != DB_VERSION_PATCH)
exit (1);
/* Block Berkeley DB 6, because (a) we haven't tested with it, (b) 6.0.20
and newer are under the AGPL, and we want use of AGPL dependencies to be
opt-in. */
if (major >= 6 && strcmp("$enable_bdb6", "yes"))
exit(2);
/* Run-time check: ensure the library claims to be the correct version. */
if (major < $svn_check_berkeley_db_major)
@ -17710,7 +18109,11 @@ _ACEOF
if ac_fn_c_try_run "$LINENO"; then :
svn_have_berkeley_db=yes
else
svn_have_berkeley_db=no
rc=$?
svn_have_berkeley_db=no
if test $rc = 2; then
svn_have_berkeley_db=no6
fi
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
conftest.$ac_objext conftest.beam conftest.$ac_ext
@ -17726,11 +18129,17 @@ fi
$as_echo "yes" >&6; }
svn_lib_berkeley_db=yes
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
if test "$svn_have_berkeley_db" = "no6"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no (found version 6, but --enable-bdb6 not specified)" >&5
$as_echo "no (found version 6, but --enable-bdb6 not specified)" >&6; }
# A warning will be printed at the end of configure.ac.
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
svn_lib_berkeley_db=no
if test "$bdb_status" = "required"; then
as_fn_error $? "Berkeley DB $db_version or newer wasn't found." "$LINENO" 5
as_fn_error $? "Berkeley DB $db_version or $db_alt_version wasn't found." "$LINENO" 5
fi
fi
fi
@ -21156,6 +21565,18 @@ $as_echo "$as_me: Disabling optimizations" >&6;}
# # do nothing
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: C compiler flags: $CFLAGS" >&5
$as_echo "$as_me: C compiler flags: $CFLAGS" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: user-defined: $CUSERFLAGS" >&5
$as_echo "$as_me: user-defined: $CUSERFLAGS" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: maintainer-mode: $CMAINTAINERFLAGS" >&5
$as_echo "$as_me: maintainer-mode: $CMAINTAINERFLAGS" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: C++ compiler flags: $CXXFLAGS" >&5
$as_echo "$as_me: C++ compiler flags: $CXXFLAGS" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: user-defined: $CXXUSERFLAGS" >&5
$as_echo "$as_me: user-defined: $CXXUSERFLAGS" >&6;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: maintainer-mode: $CXXMAINTAINERFLAGS" >&5
$as_echo "$as_me: maintainer-mode: $CXXMAINTAINERFLAGS" >&6;}
# Check whether --enable-full-version-match was given.
if test "${enable_full_version_match+set}" = set; then :
@ -25315,7 +25736,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by subversion $as_me 1.8.0, which was
This file was extended by subversion $as_me 1.8.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@ -25381,7 +25802,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
subversion config.status 1.8.0
subversion config.status 1.8.1
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
@ -27295,30 +27716,51 @@ fi
# ==== Print final messages to user ==========================================
if test "$svn_lib_berkeley_db" = "no" && test "$with_berkeley_db" != "no"; then
db_version="$SVN_FS_WANT_DB_MAJOR.$SVN_FS_WANT_DB_MINOR.$SVN_FS_WANT_DB_PATCH"
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: we have configured without BDB filesystem support
if test "$svn_have_berkeley_db" = "no6" && test "$enable_bdb6" != "no"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: We have configured without BDB filesystem support
You don't seem to have Berkeley DB version $db_version or newer
installed and linked to APR-UTIL. We have created a Makefile which will build
Subversion without support for the Berkeley DB back-end. You can find the
latest version of Berkeley DB here:
Berkeley DB 6 was found, but not used. Please re-run configure (see
./config.nice) with the '--enable-bdb6' flag to use it,
or explicitly specify '--disable-bdb6' or '--without-berkeley-db'
to silence this warning.
http://www.oracle.com/technetwork/products/berkeleydb/downloads/index.html
Please note that some versions of Berkeley DB 6+ are under the GNU Affero
General Public License, version 3:
https://oss.oracle.com/pipermail/bdb/2013-June/000056.html
or explicitly specify --without-berkeley-db to silence this warning.
The AGPL-3.0 licence may impose special requirements for making available
source code of server-side software. The text of the licence is:
https://www.gnu.org/licenses/agpl-3.0.html
http://opensource.org/licenses/AGPL-3.0
The Berkeley DB backend to Subversion is deprecated; see
http://subversion.apache.org/docs/release-notes/1.8#bdb-deprecated
The Subversion developers have not tested Subversion with Berkeley DB 6 for
technical problems or bugs.
" >&5
$as_echo "$as_me: WARNING: we have configured without BDB filesystem support
$as_echo "$as_me: WARNING: We have configured without BDB filesystem support
You don't seem to have Berkeley DB version $db_version or newer
installed and linked to APR-UTIL. We have created a Makefile which will build
Subversion without support for the Berkeley DB back-end. You can find the
latest version of Berkeley DB here:
Berkeley DB 6 was found, but not used. Please re-run configure (see
./config.nice) with the '--enable-bdb6' flag to use it,
or explicitly specify '--disable-bdb6' or '--without-berkeley-db'
to silence this warning.
http://www.oracle.com/technetwork/products/berkeleydb/downloads/index.html
Please note that some versions of Berkeley DB 6+ are under the GNU Affero
General Public License, version 3:
https://oss.oracle.com/pipermail/bdb/2013-June/000056.html
or explicitly specify --without-berkeley-db to silence this warning.
The AGPL-3.0 licence may impose special requirements for making available
source code of server-side software. The text of the licence is:
https://www.gnu.org/licenses/agpl-3.0.html
http://opensource.org/licenses/AGPL-3.0
The Berkeley DB backend to Subversion is deprecated; see
http://subversion.apache.org/docs/release-notes/1.8#bdb-deprecated
The Subversion developers have not tested Subversion with Berkeley DB 6 for
technical problems or bugs.
" >&2;}
fi

View File

@ -460,6 +460,7 @@ powerpc-apple-darwin*)
SVN_FS_WANT_DB_PATCH=14
;;
esac
db_alt_version="5.x"
# Look for libdb4.so first:
SVN_LIB_BERKELEY_DB($SVN_FS_WANT_DB_MAJOR, $SVN_FS_WANT_DB_MINOR,
$SVN_FS_WANT_DB_PATCH, [db4 db])
@ -1117,6 +1118,13 @@ elif test "$enable_optimization" = "no"; then
# # do nothing
fi
dnl Dump the current compiler options
AC_MSG_NOTICE([C compiler flags: $CFLAGS])
AC_MSG_NOTICE([ user-defined: $CUSERFLAGS])
AC_MSG_NOTICE([ maintainer-mode: $CMAINTAINERFLAGS])
AC_MSG_NOTICE([C++ compiler flags: $CXXFLAGS])
AC_MSG_NOTICE([ user-defined: $CXXUSERFLAGS])
AC_MSG_NOTICE([ maintainer-mode: $CXXMAINTAINERFLAGS])
AC_ARG_ENABLE(full-version-match,
AS_HELP_STRING([--disable-full-version-match],
@ -1504,18 +1512,28 @@ dnl Configure is long - users tend to miss warnings printed during it.
dnl Hence, print a warnings about what we did and didn't configure at the
dnl end, where people will actually see them.
if test "$svn_lib_berkeley_db" = "no" && test "$with_berkeley_db" != "no"; then
db_version="$SVN_FS_WANT_DB_MAJOR.$SVN_FS_WANT_DB_MINOR.$SVN_FS_WANT_DB_PATCH"
AC_MSG_WARN([we have configured without BDB filesystem support
if test "$svn_have_berkeley_db" = "no6" && test "$enable_bdb6" != "no"; then
AC_MSG_WARN([We have configured without BDB filesystem support
You don't seem to have Berkeley DB version $db_version or newer
installed and linked to APR-UTIL. We have created a Makefile which will build
Subversion without support for the Berkeley DB back-end. You can find the
latest version of Berkeley DB here:
Berkeley DB 6 was found, but not used. Please re-run configure (see
./config.nice) with the '--enable-bdb6' flag to use it,
or explicitly specify '--disable-bdb6' or '--without-berkeley-db'
to silence this warning.
http://www.oracle.com/technetwork/products/berkeleydb/downloads/index.html
Please note that some versions of Berkeley DB 6+ are under the GNU Affero
General Public License, version 3:
https://oss.oracle.com/pipermail/bdb/2013-June/000056.html
or explicitly specify --without-berkeley-db to silence this warning.
The AGPL-3.0 licence may impose special requirements for making available
source code of server-side software. The text of the licence is:
https://www.gnu.org/licenses/agpl-3.0.html
http://opensource.org/licenses/AGPL-3.0
The Berkeley DB backend to Subversion is deprecated; see
http://subversion.apache.org/docs/release-notes/1.8#bdb-deprecated
The Subversion developers have not tested Subversion with Berkeley DB 6 for
technical problems or bugs.
])
fi

View File

@ -37,7 +37,7 @@ SERF_VERSION=${SERF_VERSION:-"1.2.1"}
ZLIB_VERSION=${ZLIB_VERSION:-"1.2.8"}
SQLITE_VERSION=${SQLITE_VERSION:-"3.7.15.1"}
GTEST_VERSION=${GTEST_VERSION:-"1.6.0"}
HTTPD_VERSION=${HTTPD_VERSION:-"2.4.3"}
HTTPD_VERSION=${HTTPD_VERSION:-"2.4.6"}
APR_ICONV_VERSION=${APR_ICONV_VERSION:-"1.2.1"}
APR=apr-${APR_VERSION}

View File

@ -291,6 +291,39 @@ svn_client__copy_foreign(const char *url,
svn_client_ctx_t *ctx,
apr_pool_t *scratch_pool);
/* Same as the public svn_client_mergeinfo_log2 API, except for the addition
* of the TARGET_MERGEINFO_CATALOG and RESULT_POOL parameters.
*
* If TARGET_MERGEINFO_CATALOG is NULL then this acts exactly as the public
* API. If *TARGET_MERGEINFO_CATALOG is NULL, then *TARGET_MERGEINFO_CATALOG
* is set to the a mergeinfo catalog representing the mergeinfo on
* TARGET_PATH_OR_URL@TARGET_PEG_REVISION at DEPTH, (like the public API only
* depths of svn_depth_empty or svn_depth_infinity are supported) allocated in
* RESULT_POOL. Finally, if *TARGET_MERGEINFO_CATALOG is non-NULL, then it is
* assumed to be a mergeinfo catalog representing the mergeinfo on
* TARGET_PATH_OR_URL@TARGET_PEG_REVISION at DEPTH.
*
* The keys for the subtree mergeinfo are the repository root-relative
* paths of TARGET_PATH_OR_URL and/or its subtrees, regardless of whether
* TARGET_PATH_OR_URL is a URL or WC path.
*/
svn_error_t *
svn_client__mergeinfo_log(svn_boolean_t finding_merged,
const char *target_path_or_url,
const svn_opt_revision_t *target_peg_revision,
svn_mergeinfo_catalog_t *target_mergeinfo_catalog,
const char *source_path_or_url,
const svn_opt_revision_t *source_peg_revision,
const svn_opt_revision_t *source_start_revision,
const svn_opt_revision_t *source_end_revision,
svn_log_entry_receiver_t log_receiver,
void *log_receiver_baton,
svn_boolean_t discover_changed_paths,
svn_depth_t depth,
const apr_array_header_t *revprops,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
#ifdef __cplusplus
}

View File

@ -90,6 +90,11 @@ svn_stream__set_is_buffered(svn_stream_t *stream,
svn_boolean_t
svn_stream__is_buffered(svn_stream_t *stream);
/** Return the underlying file, if any, associated with the stream, or
* NULL if not available. Accessing the file bypasses the stream.
*/
apr_file_t *
svn_stream__aprfile(svn_stream_t *stream);
#ifdef __cplusplus
}

View File

@ -39,15 +39,23 @@
extern "C" {
#endif /* __cplusplus */
/* Return an error with code SVN_ERR_UNSUPPORTED_FEATURE, and an error
message referencing PATH_OR_URL, if the "server" pointed to by
RA_SESSION doesn't support Merge Tracking (e.g. is pre-1.5).
Perform temporary allocations in POOL. */
/* Equivalent to svn_ra__assert_capable_server()
for SVN_RA_CAPABILITY_MERGEINFO. */
svn_error_t *
svn_ra__assert_mergeinfo_capable_server(svn_ra_session_t *ra_session,
const char *path_or_url,
apr_pool_t *pool);
/* Return an error with code SVN_ERR_UNSUPPORTED_FEATURE, and an error
message referencing PATH_OR_URL, if the "server" pointed to by
RA_SESSION doesn't support CAPABILITY (an SVN_RA_CAPABILITY_* constant).
Perform temporary allocations in POOL. */
svn_error_t *
svn_ra__assert_capable_server(svn_ra_session_t *ra_session,
const char *capability,
const char *path_or_url,
apr_pool_t *pool);
/*** Operational Locks ***/

View File

@ -72,7 +72,7 @@ extern "C" {
*
* @since New in 1.1.
*/
#define SVN_VER_PATCH 0
#define SVN_VER_PATCH 1
/** @deprecated Provided for backward compatibility with the 1.0 API. */
@ -95,7 +95,7 @@ extern "C" {
*
* Always change this at the same time as SVN_VER_NUMTAG.
*/
#define SVN_VER_TAG " (r1490375)"
#define SVN_VER_TAG " (r1503906)"
/** Number tag: a string describing the version.
@ -121,7 +121,7 @@ extern "C" {
* When rolling a tarball, we automatically replace it with what we
* guess to be the correct revision number.
*/
#define SVN_VER_REVISION 1490375
#define SVN_VER_REVISION 1503906
/* Version strings composed from the above definitions. */

View File

@ -20,7 +20,8 @@
* under the License.
* ====================================================================
*/
#ifndef SVN_LIBSVN_CLIENT_H
#define SVN_LIBSVN_CLIENT_H
@ -208,6 +209,9 @@ svn_client__repos_location_segments(apr_array_header_t **segments,
Use the authentication baton cached in CTX to authenticate against
the repository. Use POOL for all allocations.
See also svn_client__calc_youngest_common_ancestor() to find youngest
common ancestor for already fetched history-as-mergeinfo information.
See also svn_client__youngest_common_ancestor().
*/
svn_error_t *
@ -219,6 +223,34 @@ svn_client__get_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
/* Find the common ancestor of two locations in a repository using already
fetched history-as-mergeinfo information.
Ancestry is determined by the 'copy-from' relationship and the normal
successor relationship.
Set *ANCESTOR_P to the location of the youngest common ancestor of
LOC1 and LOC2. If the locations have no common ancestor (including if
they don't have the same repository root URL), set *ANCESTOR_P to NULL.
HISTORY1, HAS_REV_ZERO_HISTORY1, HISTORY2, HAS_REV_ZERO_HISTORY2 are
history-as-mergeinfo information as returned by
svn_client__get_history_as_mergeinfo() for LOC1 and LOC2 respectively.
See also svn_client__get_youngest_common_ancestor().
*/
svn_error_t *
svn_client__calc_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
const svn_client__pathrev_t *loc1,
apr_hash_t *history1,
svn_boolean_t has_rev_zero_history1,
const svn_client__pathrev_t *loc2,
apr_hash_t *history2,
svn_boolean_t has_rev_zero_history2,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
/* Ensure that RA_SESSION's session URL matches SESSION_URL,
reparenting that session if necessary.
Store the previous session URL in *OLD_SESSION_URL (so that if the
@ -247,7 +279,8 @@ svn_client__ensure_ra_session_url(const char **old_session_url,
apr_pool_t *pool);
/* ---------------------------------------------------------------- */
/*** RA callbacks ***/
@ -329,7 +362,8 @@ svn_client__ra_make_cb_baton(svn_wc_context_t *wc_ctx,
apr_pool_t *result_pool);
/* ---------------------------------------------------------------- */
/*** Add/delete ***/
/* If AUTOPROPS is not null: Then read automatic properties matching PATH
@ -442,7 +476,8 @@ svn_client__make_local_parents(const char *path,
apr_pool_t *pool);
/* ---------------------------------------------------------------- */
/*** Checkout, update and switch ***/
/* Update a working copy LOCAL_ABSPATH to REVISION, and (if not NULL) set
@ -581,7 +616,8 @@ svn_client__switch_internal(svn_revnum_t *result_rev,
apr_pool_t *pool);
/* ---------------------------------------------------------------- */
/*** Inheritable Properties ***/
/* Convert any svn_prop_inherited_item_t elements in INHERITED_PROPS which
@ -626,7 +662,8 @@ svn_client__get_inheritable_props(apr_hash_t **wcroot_iprops,
apr_pool_t *scratch_pool);
/* ---------------------------------------------------------------- */
/*** Editor for repository diff ***/
/* Create an editor for a pure repository comparison, i.e. comparing one
@ -666,7 +703,8 @@ svn_client__get_diff_editor2(const svn_delta_editor_t **editor,
apr_pool_t *result_pool);
/* ---------------------------------------------------------------- */
/*** Editor for diff summary ***/
/* Set *CALLBACKS and *CALLBACK_BATON to a set of diff callbacks that will
@ -689,7 +727,8 @@ svn_client__get_diff_summarize_callbacks(
apr_pool_t *pool);
/* ---------------------------------------------------------------- */
/*** Copy Stuff ***/
/* This structure is used to associate a specific copy or move SRC with a
@ -730,7 +769,8 @@ typedef struct svn_client__copy_pair_t
} svn_client__copy_pair_t;
/* ---------------------------------------------------------------- */
/*** Commit Stuff ***/
/* WARNING: This is all new, untested, un-peer-reviewed conceptual
@ -944,7 +984,8 @@ svn_client__do_commit(const char *base_url,
apr_pool_t *scratch_pool);
/*** Externals (Modules) ***/
/* Handle changes to the svn:externals property described by EXTERNALS_NEW,
@ -1116,7 +1157,8 @@ svn_client__resolve_conflicts(svn_boolean_t *conflicts_remain,
svn_client_ctx_t *ctx,
apr_pool_t *scratch_pool);
#ifdef __cplusplus
}
#endif /* __cplusplus */

View File

@ -240,6 +240,13 @@ post_process_commit_item(svn_wc_committed_queue_t *queue,
remove_lock = (! keep_locks && (item->state_flags
& SVN_CLIENT_COMMIT_ITEM_LOCK_TOKEN));
/* When the node was deleted (or replaced), we need to always remove the
locks, as they're invalidated on the server. We cannot honor the
SVN_CLIENT_COMMIT_ITEM_LOCK_TOKEN flag here because it does not tell
us whether we have locked children. */
if (item->state_flags & SVN_CLIENT_COMMIT_ITEM_DELETE)
remove_lock = TRUE;
return svn_wc_queue_committed3(queue, wc_ctx, item->path,
loop_recurse, item->incoming_prop_changes,
remove_lock, !keep_changelists,

View File

@ -385,6 +385,7 @@ static svn_error_t *
verify_wc_dsts(const apr_array_header_t *copy_pairs,
svn_boolean_t make_parents,
svn_boolean_t is_move,
svn_boolean_t metadata_only,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
@ -435,8 +436,11 @@ verify_wc_dsts(const apr_array_header_t *copy_pairs,
}
/* Check that there is no unversioned obstruction */
SVN_ERR(svn_io_check_path(pair->dst_abspath_or_url, &dst_kind,
iterpool));
if (metadata_only)
dst_kind = svn_node_none;
else
SVN_ERR(svn_io_check_path(pair->dst_abspath_or_url, &dst_kind,
iterpool));
if (dst_kind != svn_node_none)
{
@ -527,6 +531,7 @@ static svn_error_t *
verify_wc_srcs_and_dsts(const apr_array_header_t *copy_pairs,
svn_boolean_t make_parents,
svn_boolean_t is_move,
svn_boolean_t metadata_only,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
@ -557,7 +562,7 @@ verify_wc_srcs_and_dsts(const apr_array_header_t *copy_pairs,
scratch_pool));
}
SVN_ERR(verify_wc_dsts(copy_pairs, make_parents, is_move, ctx,
SVN_ERR(verify_wc_dsts(copy_pairs, make_parents, is_move, metadata_only, ctx,
result_pool, iterpool));
svn_pool_destroy(iterpool);
@ -1727,8 +1732,8 @@ repos_to_wc_copy_locked(svn_boolean_t *timestamp_sleep,
/* We've already checked for physical obstruction by a working file.
But there could also be logical obstruction by an entry whose
working file happens to be missing.*/
SVN_ERR(verify_wc_dsts(copy_pairs, FALSE, FALSE, ctx,
scratch_pool, iterpool));
SVN_ERR(verify_wc_dsts(copy_pairs, FALSE, FALSE, FALSE /* metadata_only */,
ctx, scratch_pool, iterpool));
/* Decide whether the two repositories are the same or not. */
{
@ -2210,7 +2215,7 @@ try_copy(svn_boolean_t *timestamp_sleep,
if ((! srcs_are_urls) && (! dst_is_url))
{
SVN_ERR(verify_wc_srcs_and_dsts(copy_pairs, make_parents, is_move,
ctx, pool, pool));
metadata_only, ctx, pool, pool));
/* Copy or move all targets. */
if (is_move)

View File

@ -51,6 +51,7 @@
#include "private/svn_wc_private.h"
#include "private/svn_diff_private.h"
#include "private/svn_subr_private.h"
#include "private/svn_io_private.h"
#include "svn_private_config.h"
@ -807,14 +808,23 @@ diff_content_changed(svn_boolean_t *wrote_header,
* ### a non-git compatible diff application.*/
/* We deal in streams, but svn_io_run_diff2() deals in file handles,
unfortunately, so we need to make these temporary files, and then
copy the contents to our stream. */
SVN_ERR(svn_io_open_unique_file3(&outfile, &outfilename, NULL,
svn_io_file_del_on_pool_cleanup,
scratch_pool, scratch_pool));
SVN_ERR(svn_io_open_unique_file3(&errfile, &errfilename, NULL,
svn_io_file_del_on_pool_cleanup,
scratch_pool, scratch_pool));
so we may need to make temporary files and then copy the contents
to our stream. */
outfile = svn_stream__aprfile(outstream);
if (outfile)
outfilename = NULL;
else
SVN_ERR(svn_io_open_unique_file3(&outfile, &outfilename, NULL,
svn_io_file_del_on_pool_cleanup,
scratch_pool, scratch_pool));
errfile = svn_stream__aprfile(errstream);
if (errfile)
errfilename = NULL;
else
SVN_ERR(svn_io_open_unique_file3(&errfile, &errfilename, NULL,
svn_io_file_del_on_pool_cleanup,
scratch_pool, scratch_pool));
SVN_ERR(svn_io_run_diff2(".",
diff_cmd_baton->options.for_external.argv,
@ -824,20 +834,25 @@ diff_content_changed(svn_boolean_t *wrote_header,
&exitcode, outfile, errfile,
diff_cmd_baton->diff_cmd, scratch_pool));
SVN_ERR(svn_io_file_close(outfile, scratch_pool));
SVN_ERR(svn_io_file_close(errfile, scratch_pool));
/* Now, open and copy our files to our output streams. */
SVN_ERR(svn_stream_open_readonly(&stream, outfilename,
scratch_pool, scratch_pool));
SVN_ERR(svn_stream_copy3(stream, svn_stream_disown(outstream,
scratch_pool),
NULL, NULL, scratch_pool));
SVN_ERR(svn_stream_open_readonly(&stream, errfilename,
scratch_pool, scratch_pool));
SVN_ERR(svn_stream_copy3(stream, svn_stream_disown(errstream,
scratch_pool),
NULL, NULL, scratch_pool));
if (outfilename)
{
SVN_ERR(svn_io_file_close(outfile, scratch_pool));
SVN_ERR(svn_stream_open_readonly(&stream, outfilename,
scratch_pool, scratch_pool));
SVN_ERR(svn_stream_copy3(stream, svn_stream_disown(outstream,
scratch_pool),
NULL, NULL, scratch_pool));
}
if (errfilename)
{
SVN_ERR(svn_io_file_close(errfile, scratch_pool));
SVN_ERR(svn_stream_open_readonly(&stream, errfilename,
scratch_pool, scratch_pool));
SVN_ERR(svn_stream_copy3(stream, svn_stream_disown(errstream,
scratch_pool),
NULL, NULL, scratch_pool));
}
/* We have a printed a diff for this path, mark it as visited. */
*wrote_header = TRUE;

View File

@ -607,7 +607,10 @@ svn_client__arbitrary_nodes_diff(const char *local_abspath1,
if (kind1 != kind2)
return svn_error_createf(SVN_ERR_NODE_UNEXPECTED_KIND, NULL,
_("'%s' is not the same node kind as '%s'"),
local_abspath1, local_abspath2);
svn_dirent_local_style(local_abspath1,
scratch_pool),
svn_dirent_local_style(local_abspath2,
scratch_pool));
if (depth == svn_depth_unknown)
depth = svn_depth_infinity;
@ -627,7 +630,10 @@ svn_client__arbitrary_nodes_diff(const char *local_abspath1,
else
return svn_error_createf(SVN_ERR_NODE_UNEXPECTED_KIND, NULL,
_("'%s' is not a file or directory"),
kind1 == svn_node_none ?
local_abspath1 : local_abspath2);
kind1 == svn_node_none
? svn_dirent_local_style(local_abspath1,
scratch_pool)
: svn_dirent_local_style(local_abspath2,
scratch_pool));
return SVN_NO_ERROR;
}

View File

@ -712,7 +712,17 @@ run_ra_get_log(apr_array_header_t *revision_ranges,
matching_segment = bsearch(&younger_rev, log_segments->elts,
log_segments->nelts, log_segments->elt_size,
compare_rev_to_segment);
SVN_ERR_ASSERT(*matching_segment);
/* LOG_SEGMENTS is supposed to represent the history of PATHS from
the oldest to youngest revs in REVISION_RANGES. This function's
current sole caller svn_client_log5 *should* be providing
LOG_SEGMENTS that span the oldest to youngest revs in
REVISION_RANGES, even if one or more of the svn_location_segment_t's
returned have NULL path members indicating a gap in the history. So
MATCHING_SEGMENT should never be NULL, but clearly sometimes it is,
see http://svn.haxx.se/dev/archive-2013-06/0522.shtml
So to be safe we handle that case. */
if (matching_segment == NULL)
continue;
/* A segment with a NULL path means there is gap in the history.
We'll just proceed and let svn_ra_get_log2 fail with a useful
@ -850,13 +860,32 @@ svn_client_log5(const apr_array_header_t *targets,
SVN_ERR(svn_client__ensure_ra_session_url(&old_session_url, ra_session,
actual_loc->url, pool));
/* Get the svn_location_segment_t's representing the requested log ranges. */
SVN_ERR(svn_client__repos_location_segments(&log_segments, ra_session,
actual_loc->url,
actual_loc->rev, /* peg */
actual_loc->rev, /* start */
oldest_rev, /* end */
ctx, pool));
/* Save us an RA layer round trip if we are on the repository root and
know the result in advance. All the revision data has already been
validated.
*/
if (strcmp(actual_loc->url, actual_loc->repos_root_url) == 0)
{
svn_location_segment_t *segment = apr_pcalloc(pool, sizeof(*segment));
log_segments = apr_array_make(pool, 1, sizeof(segment));
segment->range_start = oldest_rev;
segment->range_end = actual_loc->rev;
segment->path = "";
APR_ARRAY_PUSH(log_segments, svn_location_segment_t *) = segment;
}
else
{
/* Get the svn_location_segment_t's representing the requested log
* ranges. */
SVN_ERR(svn_client__repos_location_segments(&log_segments, ra_session,
actual_loc->url,
actual_loc->rev, /* peg */
actual_loc->rev, /* start */
oldest_rev, /* end */
ctx, pool));
}
SVN_ERR(run_ra_get_log(revision_ranges, relative_targets, log_segments,
actual_loc, ra_session, targets, limit,

View File

@ -1307,6 +1307,9 @@ record_tree_conflict(merge_cmd_baton_t *merge_b,
{
svn_wc_context_t *wc_ctx = merge_b->ctx->wc_ctx;
if (merge_b->record_only)
return SVN_NO_ERROR;
if (merge_b->merge_source.ancestral
|| merge_b->reintegrate_merge)
{
@ -1316,8 +1319,7 @@ record_tree_conflict(merge_cmd_baton_t *merge_b,
alloc_and_store_path(&merge_b->conflicted_paths, local_abspath,
merge_b->pool);
if (!merge_b->record_only && !merge_b->dry_run)
if (!merge_b->dry_run)
{
svn_wc_conflict_description2_t *conflict;
const svn_wc_conflict_version_t *left;
@ -12029,16 +12031,17 @@ operative_rev_receiver(void *baton,
return svn_error_create(SVN_ERR_CEASE_INVOCATION, NULL, NULL);
}
/* Wrapper around svn_client_mergeinfo_log2. All arguments are as per
that API. The discover_changed_paths, depth, and revprops args to
svn_client_mergeinfo_log2 are always TRUE, svn_depth_infinity_t,
and NULL respectively.
/* Wrapper around svn_client__mergeinfo_log. All arguments are as per
that private API. The discover_changed_paths, depth, and revprops args to
svn_client__mergeinfo_log are always TRUE, svn_depth_infinity_t,
and empty array respectively.
If RECEIVER raises a SVN_ERR_CEASE_INVOCATION error, but still sets
*REVISION to a valid revnum, then clear the error. Otherwise return
any error. */
static svn_error_t*
short_circuit_mergeinfo_log(svn_boolean_t finding_merged,
short_circuit_mergeinfo_log(svn_mergeinfo_catalog_t *target_mergeinfo_cat,
svn_boolean_t finding_merged,
const char *target_path_or_url,
const svn_opt_revision_t *target_peg_revision,
const char *source_path_or_url,
@ -12048,18 +12051,25 @@ short_circuit_mergeinfo_log(svn_boolean_t finding_merged,
svn_log_entry_receiver_t receiver,
svn_revnum_t *revision,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
svn_error_t *err = svn_client_mergeinfo_log2(finding_merged,
target_path_or_url,
target_peg_revision,
source_path_or_url,
source_peg_revision,
source_start_revision,
source_end_revision,
receiver, revision,
TRUE, svn_depth_infinity,
NULL, ctx, scratch_pool);
apr_array_header_t *revprops;
svn_error_t *err;
revprops = apr_array_make(scratch_pool, 0, sizeof(const char *));
err = svn_client__mergeinfo_log(finding_merged,
target_path_or_url,
target_peg_revision,
target_mergeinfo_cat,
source_path_or_url,
source_peg_revision,
source_start_revision,
source_end_revision,
receiver, revision,
TRUE, svn_depth_infinity,
revprops, ctx, result_pool,
scratch_pool);
if (err)
{
@ -12129,6 +12139,7 @@ find_last_merged_location(svn_client__pathrev_t **base_p,
svn_opt_revision_t source_peg_rev, source_start_rev, source_end_rev,
target_opt_rev;
svn_revnum_t youngest_merged_rev = SVN_INVALID_REVNUM;
svn_mergeinfo_catalog_t target_mergeinfo_cat = NULL;
source_peg_rev.kind = svn_opt_revision_number;
source_peg_rev.value.number = source_branch->tip->rev;
@ -12141,14 +12152,15 @@ find_last_merged_location(svn_client__pathrev_t **base_p,
/* Find the youngest revision fully merged from SOURCE_BRANCH to TARGET,
if such a revision exists. */
SVN_ERR(short_circuit_mergeinfo_log(TRUE, /* Find merged */
SVN_ERR(short_circuit_mergeinfo_log(&target_mergeinfo_cat,
TRUE, /* Find merged */
target->url, &target_opt_rev,
source_branch->tip->url,
&source_peg_rev,
&source_end_rev, &source_start_rev,
operative_rev_receiver,
&youngest_merged_rev,
ctx, scratch_pool));
ctx, result_pool, scratch_pool));
if (!SVN_IS_VALID_REVNUM(youngest_merged_rev))
{
@ -12175,14 +12187,15 @@ find_last_merged_location(svn_client__pathrev_t **base_p,
(i.e. finding the youngest revision after the YCA where all revs have
been merged) that doesn't matter. */
source_end_rev.value.number = youngest_merged_rev;
SVN_ERR(short_circuit_mergeinfo_log(FALSE, /* Find eligible */
SVN_ERR(short_circuit_mergeinfo_log(&target_mergeinfo_cat,
FALSE, /* Find eligible */
target->url, &target_opt_rev,
source_branch->tip->url,
&source_peg_rev,
&source_start_rev, &source_end_rev,
operative_rev_receiver,
&oldest_eligible_rev,
ctx, scratch_pool));
ctx, scratch_pool, scratch_pool));
/* If there are revisions eligible for merging, use the oldest one
to calculate the base. Otherwise there are no operative revisions
@ -12298,9 +12311,13 @@ find_automatic_merge(svn_client__pathrev_t **base_p,
&s_t->target->loc, SVN_INVALID_REVNUM, SVN_INVALID_REVNUM,
s_t->target_ra_session, ctx, scratch_pool));
SVN_ERR(svn_client__get_youngest_common_ancestor(
&s_t->yca, s_t->source, &s_t->target->loc, s_t->source_ra_session,
ctx, result_pool, result_pool));
SVN_ERR(svn_client__calc_youngest_common_ancestor(
&s_t->yca, s_t->source, s_t->source_branch.history,
s_t->source_branch.has_r0_history,
&s_t->target->loc, s_t->target_branch.history,
s_t->target_branch.has_r0_history,
result_pool, scratch_pool));
if (! s_t->yca)
return svn_error_createf(SVN_ERR_CLIENT_NOT_READY_TO_MERGE, NULL,
_("'%s@%ld' must be ancestrally related to "

View File

@ -1651,11 +1651,11 @@ svn_client_mergeinfo_get_merged(apr_hash_t **mergeinfo_p,
return SVN_NO_ERROR;
}
svn_error_t *
svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
svn_client__mergeinfo_log(svn_boolean_t finding_merged,
const char *target_path_or_url,
const svn_opt_revision_t *target_peg_revision,
svn_mergeinfo_catalog_t *target_mergeinfo_catalog,
const char *source_path_or_url,
const svn_opt_revision_t *source_peg_revision,
const svn_opt_revision_t *source_start_revision,
@ -1666,12 +1666,15 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
svn_depth_t depth,
const apr_array_header_t *revprops,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
const char *log_target = NULL;
const char *repos_root;
const char *target_repos_relpath;
svn_mergeinfo_catalog_t target_mergeinfo_cat;
svn_ra_session_t *target_session = NULL;
svn_client__pathrev_t *pathrev;
/* A hash of paths, at or under TARGET_PATH_OR_URL, mapped to
rangelists. Not technically mergeinfo, so not using the
@ -1688,6 +1691,7 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
apr_hash_index_t *hi;
apr_pool_t *iterpool;
svn_boolean_t oldest_revs_first = TRUE;
apr_pool_t *subpool;
/* We currently only support depth = empty | infinity. */
if (depth != svn_depth_infinity && depth != svn_depth_empty)
@ -1713,6 +1717,8 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
&& (source_start_revision->kind != svn_opt_revision_unspecified))
return svn_error_create(SVN_ERR_CLIENT_BAD_REVISION, NULL, NULL);
subpool = svn_pool_create(scratch_pool);
/* We need the union of TARGET_PATH_OR_URL@TARGET_PEG_REVISION's mergeinfo
and MERGE_SOURCE_URL's history. It's not enough to do path
matching, because renames in the history of MERGE_SOURCE_URL
@ -1720,10 +1726,45 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
the target, that vastly simplifies matters (we'll have nothing to
do). */
/* This get_mergeinfo() call doubles as a mergeinfo capabilities check. */
SVN_ERR(get_mergeinfo(&target_mergeinfo_cat, &repos_root,
target_path_or_url, target_peg_revision,
depth == svn_depth_infinity, TRUE,
ctx, scratch_pool, scratch_pool));
if (target_mergeinfo_catalog)
{
if (*target_mergeinfo_catalog)
{
/* The caller provided the mergeinfo catalog for
TARGET_PATH_OR_URL, so we don't need to accquire
it ourselves. We do need to get the repos_root
though, because get_mergeinfo() won't do it for us. */
target_mergeinfo_cat = *target_mergeinfo_catalog;
SVN_ERR(svn_client__ra_session_from_path2(&target_session, &pathrev,
target_path_or_url, NULL,
target_peg_revision,
target_peg_revision,
ctx, subpool));
SVN_ERR(svn_ra_get_repos_root2(target_session, &repos_root,
scratch_pool));
}
else
{
/* The caller didn't provide the mergeinfo catalog for
TARGET_PATH_OR_URL, but wants us to pass a copy back
when we get it, so use RESULT_POOL. */
SVN_ERR(get_mergeinfo(target_mergeinfo_catalog, &repos_root,
target_path_or_url, target_peg_revision,
depth == svn_depth_infinity, TRUE,
ctx, result_pool, scratch_pool));
target_mergeinfo_cat = *target_mergeinfo_catalog;
}
}
else
{
/* The caller didn't provide the mergeinfo catalog for
TARGET_PATH_OR_URL, nor does it want a copy, so we can use
nothing but SCRATCH_POOL. */
SVN_ERR(get_mergeinfo(&target_mergeinfo_cat, &repos_root,
target_path_or_url, target_peg_revision,
depth == svn_depth_infinity, TRUE,
ctx, scratch_pool, scratch_pool));
}
if (!svn_path_is_url(target_path_or_url))
{
@ -1755,6 +1796,7 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
history. */
if (finding_merged)
{
svn_pool_destroy(subpool);
return SVN_NO_ERROR;
}
else
@ -1772,18 +1814,17 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
* ### TODO: As the source and target must be in the same repository, we
* should share a single session, tracking the two URLs separately. */
{
apr_pool_t *sesspool = svn_pool_create(scratch_pool);
svn_ra_session_t *source_session, *target_session;
svn_client__pathrev_t *pathrev;
svn_ra_session_t *source_session;
svn_revnum_t start_rev, end_rev, youngest_rev = SVN_INVALID_REVNUM;
if (! finding_merged)
{
SVN_ERR(svn_client__ra_session_from_path2(&target_session, &pathrev,
target_path_or_url, NULL,
target_peg_revision,
target_peg_revision,
ctx, sesspool));
if (!target_session)
SVN_ERR(svn_client__ra_session_from_path2(&target_session, &pathrev,
target_path_or_url, NULL,
target_peg_revision,
target_peg_revision,
ctx, subpool));
SVN_ERR(svn_client__get_history_as_mergeinfo(&target_history, NULL,
pathrev,
SVN_INVALID_REVNUM,
@ -1796,17 +1837,17 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
source_path_or_url, NULL,
source_peg_revision,
source_peg_revision,
ctx, sesspool));
ctx, subpool));
SVN_ERR(svn_client__get_revision_number(&start_rev, &youngest_rev,
ctx->wc_ctx, source_path_or_url,
source_session,
source_start_revision,
sesspool));
subpool));
SVN_ERR(svn_client__get_revision_number(&end_rev, &youngest_rev,
ctx->wc_ctx, source_path_or_url,
source_session,
source_end_revision,
sesspool));
subpool));
SVN_ERR(svn_client__get_history_as_mergeinfo(&source_history, NULL,
pathrev,
MAX(end_rev, start_rev),
@ -1817,7 +1858,7 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
oldest_revs_first = FALSE;
/* Close the source and target sessions. */
svn_pool_destroy(sesspool);
svn_pool_destroy(subpool);
}
/* Separate the explicit or inherited mergeinfo on TARGET_PATH_OR_URL,
@ -2089,6 +2130,31 @@ svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
return SVN_NO_ERROR;
}
svn_error_t *
svn_client_mergeinfo_log2(svn_boolean_t finding_merged,
const char *target_path_or_url,
const svn_opt_revision_t *target_peg_revision,
const char *source_path_or_url,
const svn_opt_revision_t *source_peg_revision,
const svn_opt_revision_t *source_start_revision,
const svn_opt_revision_t *source_end_revision,
svn_log_entry_receiver_t log_receiver,
void *log_receiver_baton,
svn_boolean_t discover_changed_paths,
svn_depth_t depth,
const apr_array_header_t *revprops,
svn_client_ctx_t *ctx,
apr_pool_t *scratch_pool)
{
return svn_client__mergeinfo_log(finding_merged, target_path_or_url,
target_peg_revision, NULL,
source_path_or_url, source_peg_revision,
source_start_revision, source_end_revision,
log_receiver, log_receiver_baton,
discover_changed_paths, depth, revprops,
ctx, scratch_pool, scratch_pool);
}
svn_error_t *
svn_client_suggest_merge_sources(apr_array_header_t **suggestions,
const char *path_or_url,

View File

@ -862,23 +862,20 @@ svn_client__repos_locations(const char **start_url,
return SVN_NO_ERROR;
}
svn_error_t *
svn_client__get_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
const svn_client__pathrev_t *loc1,
const svn_client__pathrev_t *loc2,
svn_ra_session_t *session,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
svn_client__calc_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
const svn_client__pathrev_t *loc1,
apr_hash_t *history1,
svn_boolean_t has_rev_zero_history1,
const svn_client__pathrev_t *loc2,
apr_hash_t *history2,
svn_boolean_t has_rev_zero_history2,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
apr_pool_t *sesspool = NULL;
apr_hash_t *history1, *history2;
apr_hash_index_t *hi;
svn_revnum_t yc_revision = SVN_INVALID_REVNUM;
const char *yc_relpath = NULL;
svn_boolean_t has_rev_zero_history1;
svn_boolean_t has_rev_zero_history2;
if (strcmp(loc1->repos_root_url, loc2->repos_root_url) != 0)
{
@ -886,32 +883,6 @@ svn_client__get_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
return SVN_NO_ERROR;
}
/* Open an RA session for the two locations. */
if (session == NULL)
{
sesspool = svn_pool_create(scratch_pool);
SVN_ERR(svn_client_open_ra_session2(&session, loc1->url, NULL, ctx,
sesspool, sesspool));
}
/* We're going to cheat and use history-as-mergeinfo because it
saves us a bunch of annoying custom data comparisons and such. */
SVN_ERR(svn_client__get_history_as_mergeinfo(&history1,
&has_rev_zero_history1,
loc1,
SVN_INVALID_REVNUM,
SVN_INVALID_REVNUM,
session, ctx, scratch_pool));
SVN_ERR(svn_client__get_history_as_mergeinfo(&history2,
&has_rev_zero_history2,
loc2,
SVN_INVALID_REVNUM,
SVN_INVALID_REVNUM,
session, ctx, scratch_pool));
/* Close the ra session if we opened one. */
if (sesspool)
svn_pool_destroy(sesspool);
/* Loop through the first location's history, check for overlapping
paths and ranges in the second location's history, and
remembering the youngest matching location. */
@ -964,6 +935,63 @@ svn_client__get_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
return SVN_NO_ERROR;
}
svn_error_t *
svn_client__get_youngest_common_ancestor(svn_client__pathrev_t **ancestor_p,
const svn_client__pathrev_t *loc1,
const svn_client__pathrev_t *loc2,
svn_ra_session_t *session,
svn_client_ctx_t *ctx,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool)
{
apr_pool_t *sesspool = NULL;
apr_hash_t *history1, *history2;
svn_boolean_t has_rev_zero_history1;
svn_boolean_t has_rev_zero_history2;
if (strcmp(loc1->repos_root_url, loc2->repos_root_url) != 0)
{
*ancestor_p = NULL;
return SVN_NO_ERROR;
}
/* Open an RA session for the two locations. */
if (session == NULL)
{
sesspool = svn_pool_create(scratch_pool);
SVN_ERR(svn_client_open_ra_session2(&session, loc1->url, NULL, ctx,
sesspool, sesspool));
}
/* We're going to cheat and use history-as-mergeinfo because it
saves us a bunch of annoying custom data comparisons and such. */
SVN_ERR(svn_client__get_history_as_mergeinfo(&history1,
&has_rev_zero_history1,
loc1,
SVN_INVALID_REVNUM,
SVN_INVALID_REVNUM,
session, ctx, scratch_pool));
SVN_ERR(svn_client__get_history_as_mergeinfo(&history2,
&has_rev_zero_history2,
loc2,
SVN_INVALID_REVNUM,
SVN_INVALID_REVNUM,
session, ctx, scratch_pool));
/* Close the ra session if we opened one. */
if (sesspool)
svn_pool_destroy(sesspool);
SVN_ERR(svn_client__calc_youngest_common_ancestor(ancestor_p,
loc1, history1,
has_rev_zero_history1,
loc2, history2,
has_rev_zero_history2,
result_pool,
scratch_pool));
return SVN_NO_ERROR;
}
svn_error_t *
svn_client__youngest_common_ancestor(const char **ancestor_url,
svn_revnum_t *ancestor_rev,

View File

@ -241,7 +241,7 @@ switch_internal(svn_revnum_t *result_rev,
return svn_error_createf(SVN_ERR_CLIENT_UNRELATED_RESOURCES, NULL,
_("'%s' shares no common ancestry with '%s'"),
switch_url,
svn_dirent_dirname(local_abspath, pool));
svn_dirent_local_style(local_abspath, pool));
}
wcroot_iprops = apr_hash_make(pool);

View File

@ -218,6 +218,7 @@ locate_change(struct ev2_edit_baton *eb,
change = apr_pcalloc(eb->edit_pool, sizeof(*change));
change->changing = SVN_INVALID_REVNUM;
change->deleting = SVN_INVALID_REVNUM;
change->kind = svn_node_unknown;
svn_hash_sets(eb->changes, relpath, change);
@ -1633,11 +1634,14 @@ apply_change(void **dir_baton,
change->copyfrom_path,
scratch_pool);
else
copyfrom_url = change->copyfrom_path;
{
copyfrom_url = change->copyfrom_path;
/* Make this an FS path by prepending "/" */
if (copyfrom_url[0] != '/')
copyfrom_url = apr_pstrcat(scratch_pool, "/", copyfrom_url, NULL);
/* Make this an FS path by prepending "/" */
if (copyfrom_url[0] != '/')
copyfrom_url = apr_pstrcat(scratch_pool, "/",
copyfrom_url, NULL);
}
copyfrom_rev = change->copyfrom_rev;
}

View File

@ -227,7 +227,7 @@ bdb_error_gatherer(const DB_ENV *dbenv, const char *baton, const char *msg)
SVN_BDB_ERROR_GATHERER_IGNORE(dbenv);
new_err = svn_error_createf(APR_SUCCESS, NULL, "bdb: %s", msg);
new_err = svn_error_createf(SVN_ERR_FS_BERKELEY_DB, NULL, "bdb: %s", msg);
if (error_info->pending_errors)
svn_error_compose(error_info->pending_errors, new_err);
else

View File

@ -4811,6 +4811,13 @@ base_node_origin_rev(svn_revnum_t *revision,
prev_location() does below will work. */
path = svn_fs__canonicalize_abspath(path, pool);
/* Special-case the root node (for performance reasons) */
if (strcmp(path, "/") == 0)
{
*revision = 0;
return SVN_NO_ERROR;
}
/* If we have support for the node-origins table, we'll try to use
it. */
if (bfd->format >= SVN_FS_BASE__MIN_NODE_ORIGINS_FORMAT)

View File

@ -1467,6 +1467,12 @@ delete_revprops_shard(const char *shard_path,
apr_pool_t *scratch_pool);
/* In the filesystem FS, pack all revprop shards up to min_unpacked_rev.
*
* NOTE: Keep the old non-packed shards around until after the format bump.
* Otherwise, re-running upgrade will drop the packed revprop shard but
* have no unpacked data anymore. Call upgrade_cleanup_pack_revprops after
* the bump.
*
* Use SCRATCH_POOL for temporary allocations.
*/
static svn_error_t *
@ -1507,6 +1513,29 @@ upgrade_pack_revprops(svn_fs_t *fs,
svn_pool_clear(iterpool);
}
svn_pool_destroy(iterpool);
return SVN_NO_ERROR;
}
/* In the filesystem FS, remove all non-packed revprop shards up to
* min_unpacked_rev. Use SCRATCH_POOL for temporary allocations.
* See upgrade_pack_revprops for more info.
*/
static svn_error_t *
upgrade_cleanup_pack_revprops(svn_fs_t *fs,
apr_pool_t *scratch_pool)
{
fs_fs_data_t *ffd = fs->fsap_data;
const char *revprops_shard_path;
apr_int64_t shard;
apr_int64_t first_unpacked_shard
= ffd->min_unpacked_rev / ffd->max_files_per_dir;
apr_pool_t *iterpool = svn_pool_create(scratch_pool);
const char *revsprops_dir = svn_dirent_join(fs->path, PATH_REVPROPS_DIR,
scratch_pool);
/* delete the non-packed revprops shards afterwards */
for (shard = 0; shard < first_unpacked_shard; ++shard)
{
@ -1531,6 +1560,7 @@ upgrade_body(void *baton, apr_pool_t *pool)
int format, max_files_per_dir;
const char *format_path = path_format(fs, pool);
svn_node_kind_t kind;
svn_boolean_t needs_revprop_shard_cleanup = FALSE;
/* Read the FS format number and max-files-per-dir setting. */
SVN_ERR(read_format(&format, &max_files_per_dir, format_path, pool));
@ -1582,15 +1612,28 @@ upgrade_body(void *baton, apr_pool_t *pool)
if (format < SVN_FS_FS__MIN_PACKED_FORMAT)
SVN_ERR(svn_io_file_create(path_min_unpacked_rev(fs, pool), "0\n", pool));
/* If the file system supports revision packing but not revprop packing,
pack the revprops up to the point that revision data has been packed. */
/* If the file system supports revision packing but not revprop packing
*and* the FS has been sharded, pack the revprops up to the point that
revision data has been packed. However, keep the non-packed revprop
files around until after the format bump */
if ( format >= SVN_FS_FS__MIN_PACKED_FORMAT
&& format < SVN_FS_FS__MIN_PACKED_REVPROP_FORMAT)
SVN_ERR(upgrade_pack_revprops(fs, pool));
&& format < SVN_FS_FS__MIN_PACKED_REVPROP_FORMAT
&& max_files_per_dir > 0)
{
needs_revprop_shard_cleanup = TRUE;
SVN_ERR(upgrade_pack_revprops(fs, pool));
}
/* Bump the format file. */
return write_format(format_path, SVN_FS_FS__FORMAT_NUMBER, max_files_per_dir,
TRUE, pool);
SVN_ERR(write_format(format_path, SVN_FS_FS__FORMAT_NUMBER,
max_files_per_dir, TRUE, pool));
/* Now, it is safe to remove the redundant revprop files. */
if (needs_revprop_shard_cleanup)
SVN_ERR(upgrade_cleanup_pack_revprops(fs, pool));
/* Done */
return SVN_NO_ERROR;
}
@ -3664,7 +3707,7 @@ parse_packed_revprops(svn_fs_t *fs,
svn_string_t *compressed
= svn_stringbuf__morph_into_string(revprops->packed_revprops);
svn_stringbuf_t *uncompressed = svn_stringbuf_create_empty(pool);
SVN_ERR(svn__decompress(compressed, uncompressed, 0x1000000));
SVN_ERR(svn__decompress(compressed, uncompressed, APR_SIZE_MAX));
/* read first revision number and number of revisions in the pack */
stream = svn_stream_from_stringbuf(uncompressed, scratch_pool);

View File

@ -1,4 +1,4 @@
/* This file is automatically generated from rep-cache-db.sql and .dist_sandbox/subversion-1.8.0/subversion/libsvn_fs_fs/token-map.h.
/* This file is automatically generated from rep-cache-db.sql and .dist_sandbox/subversion-1.8.1/subversion/libsvn_fs_fs/token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_CREATE_SCHEMA 0

View File

@ -151,7 +151,7 @@ typedef struct cache_entry_t
{
/* hash value derived from PATH, REVISION.
Used to short-circuit failed lookups. */
long int hash_value;
apr_uint32_t hash_value;
/* revision to which the NODE belongs */
svn_revnum_t revision;
@ -340,7 +340,12 @@ cache_lookup( fs_fs_dag_cache_t *cache
{
apr_size_t i, bucket_index;
apr_size_t path_len = strlen(path);
long int hash_value = revision;
apr_uint32_t hash_value = (apr_uint32_t)revision;
#if SVN_UNALIGNED_ACCESS_IS_OK
/* "randomizing" / distributing factor used in our hash function */
const apr_uint32_t factor = 0xd1f3da69;
#endif
/* optimistic lookup: hit the same bucket again? */
cache_entry_t *result = &cache->buckets[cache->last_hit];
@ -353,11 +358,25 @@ cache_lookup( fs_fs_dag_cache_t *cache
/* need to do a full lookup. Calculate the hash value
(HASH_VALUE has been initialized to REVISION). */
for (i = 0; i + 4 <= path_len; i += 4)
hash_value = hash_value * 0xd1f3da69 + *(const apr_uint32_t*)(path + i);
i = 0;
#if SVN_UNALIGNED_ACCESS_IS_OK
/* We relax the dependency chain between iterations by processing
two chunks from the input per hash_value self-multiplication.
The HASH_VALUE update latency is now 1 MUL latency + 1 ADD latency
per 2 chunks instead of 1 chunk.
*/
for (; i + 8 <= path_len; i += 8)
hash_value = hash_value * factor * factor
+ ( *(const apr_uint32_t*)(path + i) * factor
+ *(const apr_uint32_t*)(path + i + 4));
#endif
for (; i < path_len; ++i)
hash_value = hash_value * 33 + path[i];
/* Help GCC to minimize the HASH_VALUE update latency by splitting the
MUL 33 of the naive implementation: h = h * 33 + path[i]. This
shortens the dependency chain from 1 shift + 2 ADDs to 1 shift + 1 ADD.
*/
hash_value = hash_value * 32 + (hash_value + (unsigned char)path[i]);
bucket_index = hash_value + (hash_value >> 16);
bucket_index = (bucket_index + (bucket_index >> 8)) % BUCKET_COUNT;
@ -3364,6 +3383,14 @@ fs_node_origin_rev(svn_revnum_t *revision,
return SVN_NO_ERROR;
}
/* The root node always has ID 0, created in revision 0 and will never
use the new-style ID format. */
if (strcmp(node_id, "0") == 0)
{
*revision = 0;
return SVN_NO_ERROR;
}
/* OK, it's an old-style ID? Maybe it's cached. */
SVN_ERR(svn_fs_fs__get_node_origin(&cached_origin_id,
fs,

View File

@ -1030,6 +1030,13 @@ svn_error_t *svn_ra_get_file_revs2(svn_ra_session_t *session,
if (include_merged_revisions)
SVN_ERR(svn_ra__assert_mergeinfo_capable_server(session, NULL, pool));
if (start > end)
SVN_ERR(
svn_ra__assert_capable_server(session,
SVN_RA_CAPABILITY_GET_FILE_REVS_REVERSE,
NULL,
pool));
err = session->vtable->get_file_revs(session, path, start, end,
include_merged_revisions,
handler, handler_baton, pool);

View File

@ -38,6 +38,26 @@
#include "svn_private_config.h"
#include "private/svn_ra_private.h"
static const char *
get_path(const char *path_or_url,
svn_ra_session_t *ra_session,
apr_pool_t *pool)
{
if (path_or_url == NULL)
{
svn_error_t *err = svn_ra_get_session_url(ra_session, &path_or_url,
pool);
if (err)
{
/* The SVN_ERR_UNSUPPORTED_FEATURE error in the caller is more
important, so dummy up the session's URL and chuck this error. */
svn_error_clear(err);
return _("<repository>");
}
}
return path_or_url;
}
svn_error_t *
svn_ra__assert_mergeinfo_capable_server(svn_ra_session_t *ra_session,
const char *path_or_url,
@ -48,18 +68,7 @@ svn_ra__assert_mergeinfo_capable_server(svn_ra_session_t *ra_session,
SVN_RA_CAPABILITY_MERGEINFO, pool));
if (! mergeinfo_capable)
{
if (path_or_url == NULL)
{
svn_error_t *err = svn_ra_get_session_url(ra_session, &path_or_url,
pool);
if (err)
{
/* The SVN_ERR_UNSUPPORTED_FEATURE error is more important,
so dummy up the session's URL and chuck this error. */
svn_error_clear(err);
path_or_url = "<repository>";
}
}
path_or_url = get_path(path_or_url, ra_session, pool);
return svn_error_createf(SVN_ERR_UNSUPPORTED_FEATURE, NULL,
_("Retrieval of mergeinfo unsupported by '%s'"),
svn_path_is_url(path_or_url)
@ -69,6 +78,35 @@ svn_ra__assert_mergeinfo_capable_server(svn_ra_session_t *ra_session,
return SVN_NO_ERROR;
}
svn_error_t *
svn_ra__assert_capable_server(svn_ra_session_t *ra_session,
const char *capability,
const char *path_or_url,
apr_pool_t *pool)
{
if (!strcmp(capability, SVN_RA_CAPABILITY_MERGEINFO))
return svn_ra__assert_mergeinfo_capable_server(ra_session, path_or_url,
pool);
else
{
svn_boolean_t has;
SVN_ERR(svn_ra_has_capability(ra_session, &has, capability, pool));
if (! has)
{
path_or_url = get_path(path_or_url, ra_session, pool);
return svn_error_createf(SVN_ERR_UNSUPPORTED_FEATURE, NULL,
_("The '%s' feature is not supported by '%s'"),
capability,
svn_path_is_url(path_or_url)
? path_or_url
: svn_dirent_local_style(path_or_url,
pool));
}
}
return SVN_NO_ERROR;
}
/* Does ERR mean "the current value of the revprop isn't equal to
the *OLD_VALUE_P you gave me"?
*/

View File

@ -366,7 +366,7 @@ svn_ra_serf__get_file_revs(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, pool);
err = svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location),
err);

View File

@ -223,7 +223,7 @@ return_response_err(svn_ra_serf__handler_t *handler)
/* Try to return one of the standard errors for 301, 404, etc.,
then look for an error embedded in the response. */
return svn_error_compose_create(svn_ra_serf__error_on_status(
handler->sline.code,
handler->sline,
handler->path,
handler->location),
err);
@ -2269,7 +2269,9 @@ abort_edit(void *edit_baton,
&& handler->sline.code != 404
)
{
SVN_ERR_MALFUNCTION();
return svn_error_createf(SVN_ERR_RA_DAV_MALFORMED_DATA, NULL,
_("DELETE returned unexpected status: %d"),
handler->sline.code);
}
return SVN_NO_ERROR;

View File

@ -131,6 +131,7 @@ svn_ra_serf__get_dated_revision(svn_ra_session_t *ra_session,
svn_ra_serf__handler_t *handler;
svn_ra_serf__xml_context_t *xmlctx;
const char *report_target;
svn_error_t *err;
date_ctx = apr_palloc(pool, sizeof(*date_ctx));
date_ctx->time = tm;
@ -155,7 +156,15 @@ svn_ra_serf__get_dated_revision(svn_ra_session_t *ra_session,
*date_ctx->revision = SVN_INVALID_REVNUM;
/* ### use svn_ra_serf__error_on_status() ? */
err = svn_ra_serf__context_run_one(handler, pool);
return svn_error_trace(svn_ra_serf__context_run_one(handler, pool));
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline,
report_target,
handler->location),
err));
SVN_ERR_ASSERT(SVN_IS_VALID_REVNUM(*revision));
return SVN_NO_ERROR;
}

View File

@ -192,7 +192,7 @@ svn_ra_serf__get_locations(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, pool);
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
req_url,
handler->location),
err));

View File

@ -194,7 +194,7 @@ svn_ra_serf__get_location_segments(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, pool);
err = svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location),
err);

View File

@ -266,7 +266,7 @@ svn_ra_serf__get_locks(svn_ra_session_t *ra_session,
have existed earlier (E.g. 'svn ls http://s/svn/trunk/file@1' */
if (handler->sline.code != 404)
{
SVN_ERR(svn_ra_serf__error_on_status(handler->sline.code,
SVN_ERR(svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location));
}

View File

@ -332,7 +332,7 @@ svn_ra_serf__get_inherited_props(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, scratch_pool);
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location),
err));

View File

@ -595,7 +595,7 @@ svn_ra_serf__get_log(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, pool);
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
req_url,
handler->location),
err));

View File

@ -191,7 +191,7 @@ svn_ra_serf__get_mergeinfo(svn_ra_session_t *ra_session,
svn_boolean_t include_descendants,
apr_pool_t *pool)
{
svn_error_t *err, *err2;
svn_error_t *err;
mergeinfo_context_t *mergeinfo_ctx;
svn_ra_serf__session_t *session = ra_session->priv;
svn_ra_serf__handler_t *handler;
@ -229,15 +229,10 @@ svn_ra_serf__get_mergeinfo(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_one(handler, pool);
err2 = svn_ra_serf__error_on_status(handler->sline.code, handler->path,
handler->location);
if (err2)
{
svn_error_clear(err);
return err2;
}
SVN_ERR(err);
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline, handler->path,
handler->location),
err));
if (handler->done && apr_hash_count(mergeinfo_ctx->result_catalog))
*catalog = mergeinfo_ctx->result_catalog;

View File

@ -362,6 +362,8 @@ options_response_handler(serf_request_t *request,
capability_no);
svn_hash_sets(session->capabilities, SVN_RA_CAPABILITY_EPHEMERAL_TXNPROPS,
capability_no);
svn_hash_sets(session->capabilities, SVN_RA_CAPABILITY_GET_FILE_REVS_REVERSE,
capability_no);
/* Then see which ones we can discover. */
serf_bucket_headers_do(hdrs, capabilities_headers_iterator_callback,
@ -436,11 +438,12 @@ svn_ra_serf__v2_get_youngest_revnum(svn_revnum_t *youngest,
SVN_ERR(create_options_req(&opt_ctx, session, conn, scratch_pool));
SVN_ERR(svn_ra_serf__context_run_one(opt_ctx->handler, scratch_pool));
SVN_ERR(svn_ra_serf__error_on_status(opt_ctx->handler->sline.code,
SVN_ERR(svn_ra_serf__error_on_status(opt_ctx->handler->sline,
opt_ctx->handler->path,
opt_ctx->handler->location));
*youngest = opt_ctx->youngest_rev;
SVN_ERR_ASSERT(SVN_IS_VALID_REVNUM(*youngest));
return SVN_NO_ERROR;
}
@ -460,7 +463,7 @@ svn_ra_serf__v1_get_activity_collection(const char **activity_url,
SVN_ERR(create_options_req(&opt_ctx, session, conn, scratch_pool));
SVN_ERR(svn_ra_serf__context_run_one(opt_ctx->handler, scratch_pool));
SVN_ERR(svn_ra_serf__error_on_status(opt_ctx->handler->sline.code,
SVN_ERR(svn_ra_serf__error_on_status(opt_ctx->handler->sline,
opt_ctx->handler->path,
opt_ctx->handler->location));
@ -499,7 +502,7 @@ svn_ra_serf__exchange_capabilities(svn_ra_serf__session_t *serf_sess,
}
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(opt_ctx->handler->sline.code,
svn_ra_serf__error_on_status(opt_ctx->handler->sline,
serf_sess->session_url.path,
opt_ctx->handler->location),
err));
@ -517,6 +520,65 @@ svn_ra_serf__exchange_capabilities(svn_ra_serf__session_t *serf_sess,
}
static svn_error_t *
create_simple_options_body(serf_bucket_t **body_bkt,
void *baton,
serf_bucket_alloc_t *alloc,
apr_pool_t *pool)
{
serf_bucket_t *body;
serf_bucket_t *s;
body = serf_bucket_aggregate_create(alloc);
svn_ra_serf__add_xml_header_buckets(body, alloc);
s = SERF_BUCKET_SIMPLE_STRING("<D:options xmlns:D=\"DAV:\" />", alloc);
serf_bucket_aggregate_append(body, s);
*body_bkt = body;
return SVN_NO_ERROR;
}
svn_error_t *
svn_ra_serf__probe_proxy(svn_ra_serf__session_t *serf_sess,
apr_pool_t *scratch_pool)
{
svn_ra_serf__handler_t *handler;
handler = apr_pcalloc(scratch_pool, sizeof(*handler));
handler->handler_pool = scratch_pool;
handler->method = "OPTIONS";
handler->path = serf_sess->session_url.path;
handler->conn = serf_sess->conns[0];
handler->session = serf_sess;
/* We don't care about the response body, so discard it. */
handler->response_handler = svn_ra_serf__handle_discard_body;
/* We need a simple body, in order to send it in chunked format. */
handler->body_delegate = create_simple_options_body;
/* No special headers. */
SVN_ERR(svn_ra_serf__context_run_one(handler, scratch_pool));
/* Some versions of nginx in reverse proxy mode will return 411. They want
a Content-Length header, rather than chunked requests. We can keep other
HTTP/1.1 features, but will disable the chunking. */
if (handler->sline.code == 411)
{
serf_sess->using_chunked_requests = FALSE;
return SVN_NO_ERROR;
}
SVN_ERR(svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location));
return SVN_NO_ERROR;
}
svn_error_t *
svn_ra_serf__has_capability(svn_ra_session_t *ra_session,
svn_boolean_t *has,

View File

@ -635,7 +635,7 @@ svn_ra_serf__wait_for_props(svn_ra_serf__handler_t *handler,
err = svn_ra_serf__context_run_one(handler, scratch_pool);
err2 = svn_ra_serf__error_on_status(handler->sline.code,
err2 = svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location);

View File

@ -144,6 +144,13 @@ struct svn_ra_serf__session_t {
HTTP/1.0. Thus, we cannot send chunked requests. */
svn_boolean_t http10;
/* Should we use Transfer-Encoding: chunked for HTTP/1.1 servers. */
svn_boolean_t using_chunked_requests;
/* Do we need to detect whether the connection supports chunked requests?
i.e. is there a (reverse) proxy that does not support them? */
svn_boolean_t detect_chunking;
/* Our Version-Controlled-Configuration; may be NULL until we know it. */
const char *vcc_url;
@ -186,7 +193,7 @@ struct svn_ra_serf__session_t {
const char *activity_collection_url;
/* Are we using a proxy? */
int using_proxy;
svn_boolean_t using_proxy;
const char *proxy_username;
const char *proxy_password;
@ -1334,6 +1341,14 @@ svn_ra_serf__run_merge(const svn_commit_info_t **commit_info,
/** OPTIONS-related functions **/
/* When running with a proxy, we may need to detect and correct for problems.
This probing function will send a simple OPTIONS request to detect problems
with the connection. */
svn_error_t *
svn_ra_serf__probe_proxy(svn_ra_serf__session_t *serf_sess,
apr_pool_t *scratch_pool);
/* On HTTPv2 connections, run an OPTIONS request over CONN to fetch the
current youngest revnum, returning it in *YOUNGEST.
@ -1744,7 +1759,7 @@ svn_ra_serf__credentials_callback(char **username, char **password,
* where it necessary.
*/
svn_error_t *
svn_ra_serf__error_on_status(int status_code,
svn_ra_serf__error_on_status(serf_status_line sline,
const char *path,
const char *location);

View File

@ -696,7 +696,7 @@ svn_ra_serf__replay(svn_ra_session_t *ra_session,
err = svn_ra_serf__context_run_wait(&replay_ctx->done, session, pool);
SVN_ERR(svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location),
err));
@ -905,7 +905,7 @@ svn_ra_serf__replay_range(svn_ra_session_t *ra_session,
svn_ra_serf__handler_t *done_handler = ctx->report_handler;
done_list = done_list->next;
SVN_ERR(svn_ra_serf__error_on_status(done_handler->sline.code,
SVN_ERR(svn_ra_serf__error_on_status(done_handler->sline,
done_handler->path,
done_handler->location));
svn_pool_destroy(ctx->src_rev_pool);

View File

@ -137,6 +137,10 @@ load_http_auth_types(apr_pool_t *pool, svn_config_t *config,
runtime configuration variable. */
#define DEFAULT_HTTP_TIMEOUT 600
/* Private symbol for the 1.9-public SVN_CONFIG_OPTION_HTTP_CHUNKED_REQUESTS */
#define OPTION_HTTP_CHUNKED_REQUESTS "http-chunked-requests"
static svn_error_t *
load_config(svn_ra_serf__session_t *session,
apr_hash_t *config_hash,
@ -149,6 +153,7 @@ load_config(svn_ra_serf__session_t *session,
const char *timeout_str = NULL;
const char *exceptions;
apr_port_t proxy_port;
svn_tristate_t chunked_requests;
if (config_hash)
{
@ -225,6 +230,12 @@ load_config(svn_ra_serf__session_t *session,
SVN_CONFIG_OPTION_HTTP_MAX_CONNECTIONS,
SVN_CONFIG_DEFAULT_OPTION_HTTP_MAX_CONNECTIONS));
/* Should we use chunked transfer encoding. */
SVN_ERR(svn_config_get_tristate(config, &chunked_requests,
SVN_CONFIG_SECTION_GLOBAL,
OPTION_HTTP_CHUNKED_REQUESTS,
"auto", svn_tristate_unknown));
if (config)
server_group = svn_config_find_group(config,
session->session_url.hostname,
@ -281,6 +292,12 @@ load_config(svn_ra_serf__session_t *session,
server_group,
SVN_CONFIG_OPTION_HTTP_MAX_CONNECTIONS,
session->max_connections));
/* Should we use chunked transfer encoding. */
SVN_ERR(svn_config_get_tristate(config, &chunked_requests,
server_group,
OPTION_HTTP_CHUNKED_REQUESTS,
"auto", chunked_requests));
}
/* Don't allow the http-max-connections value to be larger than our
@ -355,6 +372,24 @@ load_config(svn_ra_serf__session_t *session,
session->using_proxy = FALSE;
}
/* Setup detect_chunking and using_chunked_requests based on
* the chunked_requests tristate */
if (chunked_requests == svn_tristate_unknown)
{
session->detect_chunking = TRUE;
session->using_chunked_requests = TRUE;
}
else if (chunked_requests == svn_tristate_true)
{
session->detect_chunking = FALSE;
session->using_chunked_requests = TRUE;
}
else /* chunked_requests == svn_tristate_false */
{
session->detect_chunking = FALSE;
session->using_chunked_requests = FALSE;
}
/* Setup authentication. */
SVN_ERR(load_http_auth_types(pool, config, server_group,
&session->authn_types));
@ -392,6 +427,7 @@ svn_ra_serf__open(svn_ra_session_t *session,
svn_ra_serf__session_t *serf_sess;
apr_uri_t url;
const char *client_string = NULL;
svn_error_t *err;
if (corrected_url)
*corrected_url = NULL;
@ -441,6 +477,10 @@ svn_ra_serf__open(svn_ra_session_t *session,
HTTP/1.1 is supported, we can upgrade. */
serf_sess->http10 = TRUE;
/* If we switch to HTTP/1.1, then we will use chunked requests. We may disable
this, if we find an intervening proxy does not support chunked requests. */
serf_sess->using_chunked_requests = TRUE;
SVN_ERR(load_config(serf_sess, config, serf_sess->pool));
serf_sess->conns[0] = apr_pcalloc(serf_sess->pool,
@ -479,7 +519,23 @@ svn_ra_serf__open(svn_ra_session_t *session,
session->priv = serf_sess;
return svn_ra_serf__exchange_capabilities(serf_sess, corrected_url, pool);
err = svn_ra_serf__exchange_capabilities(serf_sess, corrected_url, pool);
/* serf should produce a usable error code instead of APR_EGENERAL */
if (err && err->apr_err == APR_EGENERAL)
err = svn_error_createf(SVN_ERR_RA_DAV_REQUEST_FAILED, err,
_("Connection to '%s' failed"), session_URL);
SVN_ERR(err);
/* We have set up a useful connection (that doesn't indication a redirect).
If we've been told there is possibly a worrisome proxy in our path to the
server AND we switched to HTTP/1.1 (chunked requests), then probe for
problems in any proxy. */
if ((corrected_url == NULL || *corrected_url == NULL)
&& serf_sess->detect_chunking && !serf_sess->http10)
SVN_ERR(svn_ra_serf__probe_proxy(serf_sess, pool));
return SVN_NO_ERROR;
}
/* Implements svn_ra__vtable_t.reparent(). */

View File

@ -1268,7 +1268,7 @@ handle_stream(serf_request_t *request,
/* ### new field. make sure we didn't miss some initialization. */
SVN_ERR_ASSERT(fetch_ctx->handler != NULL);
err = svn_ra_serf__error_on_status(fetch_ctx->handler->sline.code,
err = svn_ra_serf__error_on_status(fetch_ctx->handler->sline,
fetch_ctx->info->name,
fetch_ctx->handler->location);
if (err)
@ -2739,7 +2739,7 @@ setup_update_report_headers(serf_bucket_t *headers,
if (report->sess->using_compression)
{
serf_bucket_headers_setn(headers, "Accept-Encoding",
"gzip;svndiff1;q=0.9,svndiff;q=0.8");
"gzip,svndiff1;q=0.9,svndiff;q=0.8");
}
else
{
@ -2891,7 +2891,7 @@ finish_report(void *report_baton,
{
return svn_error_trace(
svn_error_compose_create(
svn_ra_serf__error_on_status(handler->sline.code,
svn_ra_serf__error_on_status(handler->sline,
handler->path,
handler->location),
err));

View File

@ -373,10 +373,8 @@ conn_setup(apr_socket_t *sock,
{
conn->ssl_context = serf_bucket_ssl_encrypt_context_get(*read_bkt);
#if SERF_VERSION_AT_LEAST(1,0,0)
serf_ssl_set_hostname(conn->ssl_context,
conn->session->session_url.hostname);
#endif
serf_ssl_client_cert_provider_set(conn->ssl_context,
svn_ra_serf__handle_client_cert,
@ -477,7 +475,7 @@ connection_closed(svn_ra_serf__connection_t *conn,
{
if (why)
{
SVN_ERR_MALFUNCTION();
return svn_error_wrap_apr(why, NULL);
}
if (conn->session->using_ssl)
@ -642,10 +640,10 @@ setup_serf_req(serf_request_t *request,
{
serf_bucket_alloc_t *allocator = serf_request_get_alloc(request);
#if SERF_VERSION_AT_LEAST(1, 1, 0)
svn_spillbuf_t *buf;
svn_boolean_t set_CL = session->http10 || !session->using_chunked_requests;
if (session->http10 && body_bkt != NULL)
if (set_CL && body_bkt != NULL)
{
/* Ugh. Use HTTP/1.0 to talk to the server because we don't know if
it speaks HTTP/1.1 (and thus, chunked requests), or because the
@ -665,7 +663,6 @@ setup_serf_req(serf_request_t *request,
request_pool,
scratch_pool);
}
#endif
/* Create a request bucket. Note that this sucker is kind enough to
add a "Host" header for us. */
@ -674,15 +671,13 @@ setup_serf_req(serf_request_t *request,
/* Set the Content-Length value. This will also trigger an HTTP/1.0
request (rather than the default chunked request). */
#if SERF_VERSION_AT_LEAST(1, 1, 0)
if (session->http10)
if (set_CL)
{
if (body_bkt == NULL)
serf_bucket_request_set_CL(*req_bkt, 0);
else
serf_bucket_request_set_CL(*req_bkt, svn_spillbuf__get_size(buf));
}
#endif
*hdrs_bkt = serf_bucket_request_get_headers(*req_bkt);
@ -696,10 +691,10 @@ setup_serf_req(serf_request_t *request,
serf_bucket_headers_setn(*hdrs_bkt, "Content-Type", content_type);
}
#if SERF_VERSION_AT_LEAST(1, 1, 0)
if (session->http10)
{
serf_bucket_headers_setn(*hdrs_bkt, "Connection", "keep-alive");
#endif
}
if (accept_encoding)
{
@ -2390,17 +2385,17 @@ svn_ra_serf__report_resource(const char **report_target,
}
svn_error_t *
svn_ra_serf__error_on_status(int status_code,
svn_ra_serf__error_on_status(serf_status_line sline,
const char *path,
const char *location)
{
switch(status_code)
switch(sline.code)
{
case 301:
case 302:
case 307:
return svn_error_createf(SVN_ERR_RA_DAV_RELOCATED, NULL,
(status_code == 301)
(sline.code == 301)
? _("Repository moved permanently to '%s';"
" please relocate")
: _("Repository moved temporarily to '%s';"
@ -2415,8 +2410,20 @@ svn_ra_serf__error_on_status(int status_code,
case 423:
return svn_error_createf(SVN_ERR_FS_NO_LOCK_TOKEN, NULL,
_("'%s': no lock token available"), path);
case 411:
return svn_error_createf(SVN_ERR_RA_DAV_REQUEST_FAILED, NULL,
_("DAV request failed: 411 Content length required. The "
"server or an intermediate proxy does not accept "
"chunked encoding. Try setting 'http-chunked-requests' "
"to 'auto' or 'no' in your client configuration."));
}
if (sline.code >= 300)
return svn_error_createf(SVN_ERR_RA_DAV_REQUEST_FAILED, NULL,
_("Unexpected HTTP status %d '%s' on '%s'\n"),
sline.code, sline.reason, path);
return SVN_NO_ERROR;
}

View File

@ -615,6 +615,14 @@ svn_ra_serf__xml_cb_start(svn_ra_serf__xml_context_t *xmlctx,
}
if (scan->ns == NULL)
{
if (current->state == 0)
{
return svn_error_createf(
SVN_ERR_RA_DAV_MALFORMED_DATA, NULL,
_("XML Parsing failed: Unexpected root element '%s'"),
elemname.name);
}
xmlctx->waiting = elemname;
/* ### return? */
return SVN_NO_ERROR;

View File

@ -977,6 +977,28 @@ static svn_error_t *ra_svn_commit(svn_ra_session_t *session,
const svn_string_t *log_msg = svn_hash_gets(revprop_table,
SVN_PROP_REVISION_LOG);
if (log_msg == NULL &&
! svn_ra_svn_has_capability(conn, SVN_RA_SVN_CAP_COMMIT_REVPROPS))
{
return svn_error_createf(SVN_ERR_BAD_PROPERTY_VALUE, NULL,
_("ra_svn does not support not specifying "
"a log message with pre-1.5 servers; "
"consider passing an empty one, or upgrading "
"the server"));
}
else if (log_msg == NULL)
/* 1.5+ server. Set LOG_MSG to something, since the 'logmsg' argument
to the 'commit' protocol command is non-optional; on the server side,
only REVPROP_TABLE will be used, and LOG_MSG will be ignored. The
"svn:log" member of REVPROP_TABLE table is NULL, therefore the commit
will have a NULL log message (not just "", really NULL).
svnserve 1.5.x+ has always ignored LOG_MSG when REVPROP_TABLE was
present; this was elevated to a protocol promise in r1498550 (and
later documented in this comment) in order to fix the segmentation
fault bug described in the log message of r1498550.*/
log_msg = svn_string_create("", pool);
/* If we're sending revprops other than svn:log, make sure the server won't
silently ignore them. */
if (apr_hash_count(revprop_table) > 1 &&
@ -1456,16 +1478,19 @@ static svn_error_t *ra_svn_diff(svn_ra_session_t *session,
}
static svn_error_t *ra_svn_log(svn_ra_session_t *session,
const apr_array_header_t *paths,
svn_revnum_t start, svn_revnum_t end,
int limit,
svn_boolean_t discover_changed_paths,
svn_boolean_t strict_node_history,
svn_boolean_t include_merged_revisions,
const apr_array_header_t *revprops,
svn_log_entry_receiver_t receiver,
void *receiver_baton, apr_pool_t *pool)
static svn_error_t *
perform_ra_svn_log(svn_error_t **outer_error,
svn_ra_session_t *session,
const apr_array_header_t *paths,
svn_revnum_t start, svn_revnum_t end,
int limit,
svn_boolean_t discover_changed_paths,
svn_boolean_t strict_node_history,
svn_boolean_t include_merged_revisions,
const apr_array_header_t *revprops,
svn_log_entry_receiver_t receiver,
void *receiver_baton,
apr_pool_t *pool)
{
svn_ra_svn__session_baton_t *sess_baton = session->priv;
svn_ra_svn_conn_t *conn = sess_baton->conn;
@ -1606,8 +1631,10 @@ static svn_error_t *ra_svn_log(svn_ra_session_t *session,
cphash = NULL;
nreceived = 0;
if (! (limit && (nest_level == 0) && (++nreceived > limit)))
if (! (limit && (nest_level == 0) && (++nreceived > limit))
&& ! *outer_error)
{
svn_error_t *err;
log_entry = svn_log_entry_create(iterpool);
log_entry->changed_paths = cphash;
@ -1650,7 +1677,15 @@ static svn_error_t *ra_svn_log(svn_ra_session_t *session,
SVN_PROP_REVISION_LOG, message);
}
}
SVN_ERR(receiver(receiver_baton, log_entry, iterpool));
err = receiver(receiver_baton, log_entry, iterpool);
if (err && err->apr_err == SVN_ERR_CEASE_INVOCATION)
{
*outer_error = svn_error_trace(
svn_error_compose_create(*outer_error, err));
}
else
SVN_ERR(err);
if (log_entry->has_children)
{
nest_level++;
@ -1665,9 +1700,40 @@ static svn_error_t *ra_svn_log(svn_ra_session_t *session,
svn_pool_destroy(iterpool);
/* Read the response. */
return svn_ra_svn__read_cmd_response(conn, pool, "");
return svn_error_trace(svn_ra_svn__read_cmd_response(conn, pool, ""));
}
static svn_error_t *
ra_svn_log(svn_ra_session_t *session,
const apr_array_header_t *paths,
svn_revnum_t start, svn_revnum_t end,
int limit,
svn_boolean_t discover_changed_paths,
svn_boolean_t strict_node_history,
svn_boolean_t include_merged_revisions,
const apr_array_header_t *revprops,
svn_log_entry_receiver_t receiver,
void *receiver_baton, apr_pool_t *pool)
{
svn_error_t *outer_error = NULL;
svn_error_t *err;
err = svn_error_trace(perform_ra_svn_log(&outer_error,
session, paths,
start, end,
limit,
discover_changed_paths,
strict_node_history,
include_merged_revisions,
revprops,
receiver, receiver_baton,
pool));
return svn_error_trace(
svn_error_compose_create(outer_error,
err));
}
static svn_error_t *ra_svn_check_path(svn_ra_session_t *session,
const char *path, svn_revnum_t rev,

View File

@ -294,8 +294,12 @@ second place for auth-request point as noted below.
Upon receiving response, client switches to editor command set.
Upon successful completion of edit, server sends auth-request.
After auth exchange completes, server sends commit-info.
If rev-props is present, logmsg is ignored. Only the svn:log entry in
rev-props (if any) will be used.
commit-info: ( new-rev:number date:string author:string
? ( post-commit-err:string ) )
NOTE: when revving this, make 'logmsg' optional, or delete that parameter
and have the log message specified in 'rev-props'.
get-file
params: ( path:string [ rev:number ] want-props:bool want-contents:bool

View File

@ -172,6 +172,10 @@ svn_repos__validate_prop(const char *name,
{
svn_prop_kind_t kind = svn_property_kind2(name);
/* Allow deleting any property, even a property we don't allow to set. */
if (value == NULL)
return SVN_NO_ERROR;
/* Disallow setting non-regular properties. */
if (kind != svn_prop_regular_kind)
return svn_error_createf

View File

@ -94,7 +94,7 @@ parser_getc(parse_context_t *ctx, int *c)
}
else if (ctx->buffer_pos < ctx->buffer_size)
{
*c = ctx->parser_buffer[ctx->buffer_pos];
*c = (unsigned char)ctx->parser_buffer[ctx->buffer_pos];
ctx->buffer_pos++;
}
else
@ -107,7 +107,7 @@ parser_getc(parse_context_t *ctx, int *c)
if (ctx->buffer_pos < ctx->buffer_size)
{
*c = ctx->parser_buffer[ctx->buffer_pos];
*c = (unsigned char)ctx->parser_buffer[ctx->buffer_pos];
ctx->buffer_pos++;
}
else
@ -131,7 +131,7 @@ parser_getc_plain(parse_context_t *ctx, int *c)
{
if (ctx->buffer_pos < ctx->buffer_size)
{
*c = ctx->parser_buffer[ctx->buffer_pos];
*c = (unsigned char)ctx->parser_buffer[ctx->buffer_pos];
ctx->buffer_pos++;
return SVN_NO_ERROR;
@ -189,6 +189,32 @@ skip_to_eoln(parse_context_t *ctx, int *c)
return SVN_NO_ERROR;
}
/* Skip a UTF-8 Byte Order Mark if found. */
static APR_INLINE svn_error_t *
skip_bom(parse_context_t *ctx)
{
int ch;
SVN_ERR(parser_getc(ctx, &ch));
if (ch == 0xEF)
{
const unsigned char *buf = (unsigned char *)ctx->parser_buffer;
/* This makes assumptions about the implementation of parser_getc and
* the use of skip_bom. Specifically that parser_getc() will get all
* of the BOM characters into the parse_context_t buffer. This can
* safely be assumed as long as we only try to use skip_bom() at the
* start of the stream and the buffer is longer than 3 characters. */
SVN_ERR_ASSERT(ctx->buffer_size > ctx->buffer_pos + 1);
if (buf[ctx->buffer_pos] == 0xBB && buf[ctx->buffer_pos + 1] == 0xBF)
ctx->buffer_pos += 2;
else
SVN_ERR(parser_ungetc(ctx, ch));
}
else
SVN_ERR(parser_ungetc(ctx, ch));
return SVN_NO_ERROR;
}
/* Parse a single option value */
static svn_error_t *
@ -450,6 +476,8 @@ svn_config__parse_stream(svn_config_t *cfg, svn_stream_t *stream,
ctx->buffer_pos = 0;
ctx->buffer_size = 0;
SVN_ERR(skip_bom(ctx));
do
{
SVN_ERR(skip_whitespace(ctx, &ch, &count));
@ -806,6 +834,8 @@ svn_config_ensure(const char *config_dir, apr_pool_t *pool)
"### http-max-connections Maximum number of parallel server" NL
"### connections to use for any given" NL
"### HTTP operation." NL
"### http-chunked-requests Whether to use chunked transfer" NL
"### encoding for HTTP requests body." NL
"### neon-debug-mask Debug mask for Neon HTTP library" NL
"### ssl-authority-files List of files, each of a trusted CA"
NL

View File

@ -156,42 +156,28 @@ send_option(int sd, char *buf, size_t n, const char *option, const char *value,
return (strncmp(buf, "OK", 2) == 0);
}
/* Implementation of svn_auth__password_get_t that retrieves the password
from gpg-agent */
/* Locate a running GPG Agent, and return an open file descriptor
* for communication with the agent in *NEW_SD. If no running agent
* can be found, set *NEW_SD to -1. */
static svn_error_t *
password_get_gpg_agent(svn_boolean_t *done,
const char **password,
apr_hash_t *creds,
const char *realmstring,
const char *username,
apr_hash_t *parameters,
svn_boolean_t non_interactive,
apr_pool_t *pool)
find_running_gpg_agent(int *new_sd, apr_pool_t *pool)
{
int sd;
char *buffer;
char *gpg_agent_info = NULL;
const char *socket_name = NULL;
const char *request = NULL;
const char *p = NULL;
char *ep = NULL;
char *buffer;
int sd;
apr_array_header_t *socket_details;
const char *request = NULL;
const char *cache_id = NULL;
struct sockaddr_un addr;
const char *tty_name;
const char *tty_type;
const char *lc_ctype;
const char *display;
const char *socket_name = NULL;
svn_checksum_t *digest = NULL;
char *password_prompt;
char *realm_prompt;
*done = FALSE;
*new_sd = -1;
gpg_agent_info = getenv("GPG_AGENT_INFO");
if (gpg_agent_info != NULL)
{
apr_array_header_t *socket_details;
socket_details = svn_cstring_split(gpg_agent_info, ":", TRUE,
pool);
socket_name = APR_ARRAY_IDX(socket_details, 0, const char *);
@ -201,6 +187,8 @@ password_get_gpg_agent(svn_boolean_t *done,
if (socket_name != NULL)
{
struct sockaddr_un addr;
addr.sun_family = AF_UNIX;
strncpy(addr.sun_path, socket_name, sizeof(addr.sun_path) - 1);
addr.sun_path[sizeof(addr.sun_path) - 1] = '\0';
@ -273,6 +261,44 @@ password_get_gpg_agent(svn_boolean_t *done,
return SVN_NO_ERROR;
}
*new_sd = sd;
return SVN_NO_ERROR;
}
/* Implementation of svn_auth__password_get_t that retrieves the password
from gpg-agent */
static svn_error_t *
password_get_gpg_agent(svn_boolean_t *done,
const char **password,
apr_hash_t *creds,
const char *realmstring,
const char *username,
apr_hash_t *parameters,
svn_boolean_t non_interactive,
apr_pool_t *pool)
{
int sd;
const char *p = NULL;
char *ep = NULL;
char *buffer;
const char *request = NULL;
const char *cache_id = NULL;
const char *tty_name;
const char *tty_type;
const char *lc_ctype;
const char *display;
svn_checksum_t *digest = NULL;
char *password_prompt;
char *realm_prompt;
*done = FALSE;
SVN_ERR(find_running_gpg_agent(&sd, pool));
if (sd == -1)
return SVN_NO_ERROR;
buffer = apr_palloc(pool, BUFFER_SIZE);
/* Send TTY_NAME to the gpg-agent daemon. */
tty_name = getenv("GPG_TTY");
if (tty_name != NULL)
@ -283,11 +309,6 @@ password_get_gpg_agent(svn_boolean_t *done,
return SVN_NO_ERROR;
}
}
else
{
close(sd);
return SVN_NO_ERROR;
}
/* Send TTY_TYPE to the gpg-agent daemon. */
tty_type = getenv("TERM");
@ -299,11 +320,6 @@ password_get_gpg_agent(svn_boolean_t *done,
return SVN_NO_ERROR;
}
}
else
{
close(sd);
return SVN_NO_ERROR;
}
/* Compute LC_CTYPE. */
lc_ctype = getenv("LC_ALL");
@ -388,8 +404,8 @@ password_get_gpg_agent(svn_boolean_t *done,
password in GPG Agent if that's how this particular integration
worked. But it isn't. GPG Agent stores the password provided by
the user via the pinentry program immediately upon its provision
(and regardless of its accuracy as passwords go), so there's
nothing really to do here. */
(and regardless of its accuracy as passwords go), so we just need
to check if a running GPG Agent exists. */
static svn_error_t *
password_set_gpg_agent(svn_boolean_t *done,
apr_hash_t *creds,
@ -400,6 +416,15 @@ password_set_gpg_agent(svn_boolean_t *done,
svn_boolean_t non_interactive,
apr_pool_t *pool)
{
int sd;
*done = FALSE;
SVN_ERR(find_running_gpg_agent(&sd, pool));
if (sd == -1)
return SVN_NO_ERROR;
close(sd);
*done = TRUE;
return SVN_NO_ERROR;

View File

@ -1,4 +1,4 @@
/* This file is automatically generated from internal_statements.sql and .dist_sandbox/subversion-1.8.0/subversion/libsvn_subr/token-map.h.
/* This file is automatically generated from internal_statements.sql and .dist_sandbox/subversion-1.8.1/subversion/libsvn_subr/token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_INTERNAL_SAVEPOINT_SVN 0

View File

@ -3533,6 +3533,9 @@ svn_io_read_length_line(apr_file_t *file, char *buf, apr_size_t *limit,
apr_size_t bytes_read = 0;
char *eol;
if (to_read == 0)
break;
/* read data block (or just a part of it) */
SVN_ERR(svn_io_file_read_full2(file, buf, to_read,
&bytes_read, &eof, pool));

View File

@ -251,6 +251,7 @@ struct svn_atomic_namespace__t
*/
static svn_mutex__t *thread_mutex = NULL;
#if APR_HAS_MMAP
/* Initialization flag for the above used by svn_atomic__init_once.
*/
static volatile svn_atomic_t mutex_initialized = FALSE;
@ -266,6 +267,7 @@ init_thread_mutex(void *baton, apr_pool_t *pool)
return svn_mutex__init(&thread_mutex, USE_THREAD_MUTEX, global_pool);
}
#endif /* APR_HAS_MMAP */
/* Utility that acquires our global mutex and converts error types.
*/
@ -297,6 +299,7 @@ unlock(struct mutex_t *mutex, svn_error_t * outer_err)
unlock_err));
}
#if APR_HAS_MMAP
/* The last user to close a particular namespace should also remove the
* lock file. Failure to do so, however, does not affect further uses
* of the same namespace.
@ -318,6 +321,7 @@ delete_lock_file(void *arg)
return status;
}
#endif /* APR_HAS_MMAP */
/* Validate the ATOMIC parameter, i.e it's address. Correct code will
* never need this but if someone should accidentally to use a NULL or
@ -351,7 +355,11 @@ return_atomic(svn_named_atomic__t **atomic,
svn_boolean_t
svn_named_atomic__is_supported(void)
{
#ifdef _WIN32
#if !APR_HAS_MMAP
return FALSE;
#elif !defined(_WIN32)
return TRUE;
#else
static svn_tristate_t result = svn_tristate_unknown;
if (result == svn_tristate_unknown)
@ -373,9 +381,7 @@ svn_named_atomic__is_supported(void)
}
return result == svn_tristate_true;
#else
return TRUE;
#endif
#endif /* _WIN32 */
}
svn_boolean_t
@ -389,6 +395,9 @@ svn_atomic_namespace__create(svn_atomic_namespace__t **ns,
const char *name,
apr_pool_t *result_pool)
{
#if !APR_HAS_MMAP
return svn_error_create(APR_ENOTIMPL, NULL, NULL);
#else
apr_status_t apr_err;
svn_error_t *err;
apr_file_t *file;
@ -489,6 +498,7 @@ svn_atomic_namespace__create(svn_atomic_namespace__t **ns,
/* Unlock to allow other processes may access the shared memory as well.
*/
return unlock(&new_ns->mutex, err);
#endif /* APR_HAS_MMAP */
}
svn_error_t *

View File

@ -140,9 +140,9 @@ struct svn_sqlite__value_t
int sqlite_err__temp = (x); \
if (sqlite_err__temp != SQLITE_OK) \
return svn_error_createf(SQLITE_ERROR_CODE(sqlite_err__temp), \
NULL, "sqlite: %s (S%d)", \
sqlite3_errmsg((db)->db3), \
sqlite_err__temp); \
NULL, "sqlite[S%d]: %s", \
sqlite_err__temp, \
sqlite3_errmsg((db)->db3)); \
} while (0)
#define SQLITE_ERR_MSG(x, msg) do \
@ -150,8 +150,8 @@ struct svn_sqlite__value_t
int sqlite_err__temp = (x); \
if (sqlite_err__temp != SQLITE_OK) \
return svn_error_createf(SQLITE_ERROR_CODE(sqlite_err__temp), \
NULL, "sqlite: %s (S%d)", (msg), \
sqlite_err__temp); \
NULL, "sqlite[S%d]: %s", \
sqlite_err__temp, msg); \
} while (0)
@ -173,9 +173,9 @@ exec_sql2(svn_sqlite__db_t *db, const char *sql, int ignored_err)
if (sqlite_err != SQLITE_OK && sqlite_err != ignored_err)
{
svn_error_t *err = svn_error_createf(SQLITE_ERROR_CODE(sqlite_err), NULL,
_("sqlite: %s (S%d),"
_("sqlite[S%d]: %s,"
" executing statement '%s'"),
err_msg, sqlite_err, sql);
sqlite_err, err_msg, sql);
sqlite3_free(err_msg);
return err;
}
@ -292,8 +292,8 @@ svn_sqlite__step(svn_boolean_t *got_row, svn_sqlite__stmt_t *stmt)
svn_error_t *err1, *err2;
err1 = svn_error_createf(SQLITE_ERROR_CODE(sqlite_result), NULL,
"sqlite: %s (S%d)",
sqlite3_errmsg(stmt->db->db3), sqlite_result);
"sqlite[S%d]: %s",
sqlite_result, sqlite3_errmsg(stmt->db->db3));
err2 = svn_sqlite__reset(stmt);
return svn_error_compose_create(err1, err2);
}
@ -744,7 +744,7 @@ init_sqlite(void *baton, apr_pool_t *pool)
int err = sqlite3_config(SQLITE_CONFIG_MULTITHREAD);
if (err != SQLITE_OK && err != SQLITE_MISUSE)
return svn_error_createf(SQLITE_ERROR_CODE(err), NULL,
_("Could not configure SQLite (S%d)"), err);
_("Could not configure SQLite [S%d]"), err);
}
SQLITE_ERR_MSG(sqlite3_initialize(), _("Could not initialize SQLite"));

View File

@ -56,6 +56,7 @@ struct svn_stream_t {
svn_stream_mark_fn_t mark_fn;
svn_stream_seek_fn_t seek_fn;
svn_stream__is_buffered_fn_t is_buffered_fn;
apr_file_t *file; /* Maybe NULL */
};
@ -81,6 +82,7 @@ svn_stream_create(void *baton, apr_pool_t *pool)
stream->mark_fn = NULL;
stream->seek_fn = NULL;
stream->is_buffered_fn = NULL;
stream->file = NULL;
return stream;
}
@ -913,6 +915,7 @@ svn_stream_from_aprfile2(apr_file_t *file,
svn_stream_set_mark(stream, mark_handler_apr);
svn_stream_set_seek(stream, seek_handler_apr);
svn_stream__set_is_buffered(stream, is_buffered_handler_apr);
stream->file = file;
if (! disown)
svn_stream_set_close(stream, close_handler_apr);
@ -920,6 +923,12 @@ svn_stream_from_aprfile2(apr_file_t *file,
return stream;
}
apr_file_t *
svn_stream__aprfile(svn_stream_t *stream)
{
return stream->file;
}
/* Compressed stream support */

View File

@ -1944,7 +1944,11 @@ svn_subst_translate_string2(svn_string_t **new_value,
return SVN_NO_ERROR;
}
if (encoding)
if (encoding && !strcmp(encoding, "UTF-8"))
{
val_utf8 = value->data;
}
else if (encoding)
{
SVN_ERR(svn_utf_cstring_to_utf8_ex2(&val_utf8, value->data,
encoding, scratch_pool));

View File

@ -233,6 +233,8 @@ xlate_alloc_handle(xlate_handle_node_t **ret,
else if (apr_err != APR_SUCCESS)
{
const char *errstr;
char apr_strerr[512];
/* Can't use svn_error_wrap_apr here because it calls functions in
this file, leading to infinite recursion. */
if (frompage == SVN_APR_LOCALE_CHARSET)
@ -248,7 +250,13 @@ xlate_alloc_handle(xlate_handle_node_t **ret,
_("Can't create a character converter from "
"'%s' to '%s'"), frompage, topage);
return svn_error_create(apr_err, NULL, errstr);
/* Just put the error on the stack, since svn_error_create duplicates it
later. APR_STRERR will be in the local encoding, not in UTF-8, though.
*/
svn_strerror(apr_err, apr_strerr, sizeof(apr_strerr));
return svn_error_create(apr_err,
svn_error_create(apr_err, NULL, apr_strerr),
errstr);
}
/* Allocate and initialize the node. */

View File

@ -148,6 +148,7 @@ process_committed_leaf(svn_wc__db_t *db,
db, local_abspath,
FALSE /* keep_as_working */,
FALSE /* queue_deletes */,
TRUE /* remove_locks */,
(! via_recurse)
? new_revnum : SVN_INVALID_REVNUM,
NULL, NULL,

View File

@ -110,6 +110,7 @@ crop_children(svn_wc__db_t *db,
SVN_ERR(svn_wc__db_base_remove(db, child_abspath,
FALSE /* keep_as_working */,
FALSE /* queue_deletes */,
FALSE /* remove_locks */,
SVN_INVALID_REVNUM,
NULL, NULL, iterpool));

View File

@ -1413,6 +1413,7 @@ svn_wc__external_remove(svn_wc_context_t *wc_ctx,
SVN_ERR(svn_wc__db_base_remove(wc_ctx->db, local_abspath,
FALSE /* keep_as_working */,
TRUE /* queue_deletes */,
FALSE /* remove_locks */,
SVN_INVALID_REVNUM,
NULL, NULL, scratch_pool));
SVN_ERR(svn_wc__wq_run(wc_ctx->db, local_abspath,

View File

@ -924,6 +924,7 @@ mark_directory_edited(struct dir_baton *db, apr_pool_t *scratch_pool)
do_notification(db->edit_baton, db->local_abspath, svn_node_dir,
svn_wc_notify_tree_conflict, scratch_pool);
db->already_notified = TRUE;
}
return SVN_NO_ERROR;
@ -1813,6 +1814,7 @@ delete_entry(const char *path,
SVN_ERR(svn_wc__db_base_remove(eb->db, local_abspath,
FALSE /* keep_as_working */,
FALSE /* queue_deletes */,
FALSE /* remove_locks */,
SVN_INVALID_REVNUM /* not_present_rev */,
NULL, NULL,
scratch_pool));
@ -1911,7 +1913,7 @@ delete_entry(const char *path,
{
/* Delete, and do not leave a not-present node. */
SVN_ERR(svn_wc__db_base_remove(eb->db, local_abspath,
keep_as_working, queue_deletes,
keep_as_working, queue_deletes, FALSE,
SVN_INVALID_REVNUM /* not_present_rev */,
tree_conflict, NULL,
scratch_pool));
@ -1920,7 +1922,7 @@ delete_entry(const char *path,
{
/* Delete, leaving a not-present node. */
SVN_ERR(svn_wc__db_base_remove(eb->db, local_abspath,
keep_as_working, queue_deletes,
keep_as_working, queue_deletes, FALSE,
*eb->target_revision,
tree_conflict, NULL,
scratch_pool));
@ -1939,8 +1941,19 @@ delete_entry(const char *path,
/* Notify. */
if (tree_conflict)
do_notification(eb, local_abspath, svn_node_unknown,
svn_wc_notify_tree_conflict, scratch_pool);
{
if (eb->conflict_func)
SVN_ERR(svn_wc__conflict_invoke_resolver(eb->db, local_abspath,
tree_conflict,
NULL /* merge_options */,
eb->conflict_func,
eb->conflict_baton,
eb->cancel_func,
eb->cancel_baton,
scratch_pool));
do_notification(eb, local_abspath, svn_node_unknown,
svn_wc_notify_tree_conflict, scratch_pool);
}
else
{
svn_wc_notify_action_t action = svn_wc_notify_update_delete;
@ -2289,6 +2302,16 @@ add_directory(const char *path,
if (tree_conflict != NULL)
{
if (eb->conflict_func)
SVN_ERR(svn_wc__conflict_invoke_resolver(eb->db, db->local_abspath,
tree_conflict,
NULL /* merge_options */,
eb->conflict_func,
eb->conflict_baton,
eb->cancel_func,
eb->cancel_baton,
pool));
db->already_notified = TRUE;
do_notification(eb, db->local_abspath, svn_node_dir,
svn_wc_notify_tree_conflict, pool);
@ -2907,7 +2930,7 @@ close_directory(void *dir_baton,
eb->conflict_func,
eb->conflict_baton,
eb->cancel_func,
eb->conflict_baton,
eb->cancel_baton,
scratch_pool));
/* Notify of any prop changes on this directory -- but do nothing if
@ -3380,6 +3403,16 @@ add_file(const char *path,
tree_conflict, NULL,
scratch_pool));
if (eb->conflict_func)
SVN_ERR(svn_wc__conflict_invoke_resolver(eb->db, fb->local_abspath,
tree_conflict,
NULL /* merge_options */,
eb->conflict_func,
eb->conflict_baton,
eb->cancel_func,
eb->cancel_baton,
scratch_pool));
fb->already_notified = TRUE;
do_notification(eb, fb->local_abspath, svn_node_file,
svn_wc_notify_tree_conflict, scratch_pool);
@ -4703,6 +4736,7 @@ close_edit(void *edit_baton,
SVN_ERR(svn_wc__db_base_remove(eb->db, eb->target_abspath,
FALSE /* keep_as_working */,
FALSE /* queue_deletes */,
FALSE /* remove_locks */,
SVN_INVALID_REVNUM,
NULL, NULL, scratch_pool));
}

View File

@ -2196,13 +2196,15 @@ svn_wc_upgrade(svn_wc_context_t *wc_ctx,
upgrade_working_copy_baton_t cb_baton;
svn_error_t *err;
int result_format;
svn_boolean_t bumped_format;
/* Try upgrading a wc-ng-style working copy. */
SVN_ERR(svn_wc__db_open(&db, NULL /* ### config */, TRUE, FALSE,
scratch_pool, scratch_pool));
err = svn_wc__db_bump_format(&result_format, local_abspath, db,
err = svn_wc__db_bump_format(&result_format, &bumped_format,
db, local_abspath,
scratch_pool);
if (err)
{
@ -2224,6 +2226,17 @@ svn_wc_upgrade(svn_wc_context_t *wc_ctx,
SVN_ERR_ASSERT(result_format == SVN_WC__VERSION);
if (bumped_format && notify_func)
{
svn_wc_notify_t *notify;
notify = svn_wc_create_notify(local_abspath,
svn_wc_notify_upgraded_path,
scratch_pool);
notify_func(notify_baton, notify, scratch_pool);
}
return SVN_NO_ERROR;
}

View File

@ -1,4 +1,4 @@
/* This file is automatically generated from wc-checks.sql and .dist_sandbox/subversion-1.8.0/subversion/libsvn_wc/token-map.h.
/* This file is automatically generated from wc-checks.sql and .dist_sandbox/subversion-1.8.1/subversion/libsvn_wc/token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_VERIFICATION_TRIGGERS 0

View File

@ -1,4 +1,4 @@
/* This file is automatically generated from wc-metadata.sql and .dist_sandbox/subversion-1.8.0/subversion/libsvn_wc/token-map.h.
/* This file is automatically generated from wc-metadata.sql and .dist_sandbox/subversion-1.8.1/subversion/libsvn_wc/token-map.h.
* Do not edit this file -- edit the source and rerun gen-make.py */
#define STMT_CREATE_SCHEMA 0

File diff suppressed because it is too large Load Diff

View File

@ -472,6 +472,10 @@ WHERE wc_id = ?1
DELETE FROM lock
WHERE repos_id = ?1 AND repos_relpath = ?2
-- STMT_DELETE_LOCK_RECURSIVELY
DELETE FROM lock
WHERE repos_id = ?1 AND (repos_relpath = ?2 OR IS_STRICT_DESCENDANT_OF(repos_relpath, ?2))
-- STMT_CLEAR_BASE_NODE_RECURSIVE_DAV_CACHE
UPDATE nodes SET dav_cache = NULL
WHERE dav_cache IS NOT NULL AND wc_id = ?1 AND op_depth = 0

View File

@ -2086,6 +2086,7 @@ db_base_remove(svn_wc__db_wcroot_t *wcroot,
svn_wc__db_t *db, /* For checking conflicts */
svn_boolean_t keep_as_working,
svn_boolean_t queue_deletes,
svn_boolean_t remove_locks,
svn_revnum_t not_present_revision,
svn_skel_t *conflict,
svn_skel_t *work_items,
@ -2106,6 +2107,16 @@ db_base_remove(svn_wc__db_wcroot_t *wcroot,
wcroot, local_relpath,
scratch_pool, scratch_pool));
if (remove_locks)
{
svn_sqlite__stmt_t *lock_stmt;
SVN_ERR(svn_sqlite__get_statement(&lock_stmt, wcroot->sdb,
STMT_DELETE_LOCK_RECURSIVELY));
SVN_ERR(svn_sqlite__bindf(lock_stmt, "is", repos_id, repos_relpath));
SVN_ERR(svn_sqlite__step_done(lock_stmt));
}
if (status == svn_wc__db_status_normal
&& keep_as_working)
{
@ -2333,6 +2344,7 @@ svn_wc__db_base_remove(svn_wc__db_t *db,
const char *local_abspath,
svn_boolean_t keep_as_working,
svn_boolean_t queue_deletes,
svn_boolean_t remove_locks,
svn_revnum_t not_present_revision,
svn_skel_t *conflict,
svn_skel_t *work_items,
@ -2349,7 +2361,7 @@ svn_wc__db_base_remove(svn_wc__db_t *db,
SVN_WC__DB_WITH_TXN(db_base_remove(wcroot, local_relpath,
db, keep_as_working, queue_deletes,
not_present_revision,
remove_locks, not_present_revision,
conflict, work_items, scratch_pool),
wcroot);
@ -10814,7 +10826,7 @@ commit_node(svn_wc__db_wcroot_t *wcroot,
svn_sqlite__stmt_t *lock_stmt;
SVN_ERR(svn_sqlite__get_statement(&lock_stmt, wcroot->sdb,
STMT_DELETE_LOCK));
STMT_DELETE_LOCK_RECURSIVELY));
SVN_ERR(svn_sqlite__bindf(lock_stmt, "is", repos_id, repos_relpath));
SVN_ERR(svn_sqlite__step_done(lock_stmt));
}
@ -11058,7 +11070,7 @@ bump_node_revision(svn_wc__db_wcroot_t *wcroot,
revision != new_rev)))
{
return svn_error_trace(db_base_remove(wcroot, local_relpath,
db, FALSE, FALSE,
db, FALSE, FALSE, FALSE,
SVN_INVALID_REVNUM,
NULL, NULL, scratch_pool));
}
@ -14978,14 +14990,18 @@ svn_wc__db_verify(svn_wc__db_t *db,
svn_error_t *
svn_wc__db_bump_format(int *result_format,
const char *wcroot_abspath,
svn_boolean_t *bumped_format,
svn_wc__db_t *db,
const char *wcroot_abspath,
apr_pool_t *scratch_pool)
{
svn_sqlite__db_t *sdb;
svn_error_t *err;
int format;
if (bumped_format)
*bumped_format = FALSE;
/* Do not scan upwards for a working copy root here to prevent accidental
* upgrades of any working copies the WCROOT might be nested in.
* Just try to open a DB at the specified path instead. */
@ -15020,7 +15036,10 @@ svn_wc__db_bump_format(int *result_format,
SVN_ERR(svn_sqlite__read_schema_version(&format, sdb, scratch_pool));
err = svn_wc__upgrade_sdb(result_format, wcroot_abspath,
sdb, format, scratch_pool);
sdb, format, scratch_pool);
if (err == SVN_NO_ERROR && bumped_format)
*bumped_format = (*result_format > format);
/* Make sure we return a different error than expected for upgrades from
entries */

View File

@ -702,6 +702,9 @@ svn_wc__db_base_add_not_present_node(svn_wc__db_t *db,
(With KEEP_AS_WORKING TRUE, this is a no-op, as everything is
automatically shadowed by the created copy)
If REMOVE_LOCKS is TRUE, all locks of this node and any subnodes
are also removed. This is to be done during commit of deleted nodes.
If NOT_PRESENT_REVISION specifies a valid revision a not-present
node is installed in BASE node with kind NOT_PRESENT_KIND after
deleting.
@ -715,6 +718,7 @@ svn_wc__db_base_remove(svn_wc__db_t *db,
const char *local_abspath,
svn_boolean_t keep_as_working,
svn_boolean_t queue_deletes,
svn_boolean_t remove_locks,
svn_revnum_t not_present_revision,
svn_skel_t *conflict,
svn_skel_t *work_items,
@ -2909,11 +2913,15 @@ svn_wc__db_upgrade_get_repos_id(apr_int64_t *repos_id,
* Upgrading subdirectories of a working copy is not supported.
* If WCROOT_ABSPATH is not a working copy root SVN_ERR_WC_INVALID_OP_ON_CWD
* is returned.
*
* If BUMPED_FORMAT is not NULL, set *BUMPED_FORMAT to TRUE if the format
* was bumped or to FALSE if the wc was already at the resulting format.
*/
svn_error_t *
svn_wc__db_bump_format(int *result_format,
const char *wcroot_abspath,
svn_boolean_t *bumped_format,
svn_wc__db_t *db,
const char *wcroot_abspath,
apr_pool_t *scratch_pool);
/* @} */

View File

@ -1988,8 +1988,12 @@ svn_wc__db_update_moved_away_conflict_victim(svn_wc__db_t *db,
/* Send all queued up notifications. */
SVN_ERR(svn_wc__db_update_move_list_notify(wcroot,
old_version->peg_rev,
new_version->peg_rev,
(old_version
? old_version->peg_rev
: SVN_INVALID_REVNUM),
(new_version
? new_version->peg_rev
: SVN_INVALID_REVNUM),
notify_func, notify_baton,
scratch_pool));
if (notify_func)
@ -2395,7 +2399,9 @@ svn_wc__db_resolve_delete_raise_moved_away(svn_wc__db_t *db,
wcroot);
SVN_ERR(svn_wc__db_update_move_list_notify(wcroot,
old_version->peg_rev,
(old_version
? old_version->peg_rev
: SVN_INVALID_REVNUM),
(new_version
? new_version->peg_rev
: SVN_INVALID_REVNUM),

View File

@ -434,6 +434,8 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
svn_boolean_t always_check = FALSE;
int wc_format = 0;
const char *adm_relpath;
/* Non-NULL if WCROOT is found through a symlink: */
const char *symlink_wcroot_abspath = NULL;
/* ### we need more logic for finding the database (if it is located
### outside of the wcroot) and then managing all of that within DB.
@ -611,6 +613,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
if (found_wcroot)
break;
symlink_wcroot_abspath = local_abspath;
SVN_ERR(read_link_target(&local_abspath, local_abspath,
scratch_pool));
try_symlink_as_dir:
@ -632,6 +635,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
local_abspath = svn_dirent_dirname(local_abspath, scratch_pool);
moved_upwards = TRUE;
symlink_wcroot_abspath = NULL;
/* Is the parent directory recorded in our hash? */
found_wcroot = svn_hash_gets(db->dir_data, local_abspath);
@ -669,7 +673,10 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
(ie. where we found it). */
err = svn_wc__db_pdh_create_wcroot(wcroot,
apr_pstrdup(db->state_pool, local_abspath),
apr_pstrdup(db->state_pool,
symlink_wcroot_abspath
? symlink_wcroot_abspath
: local_abspath),
sdb, wc_id, FORMAT_FROM_SDB,
db->verify_format, db->enforce_empty_wq,
db->state_pool, scratch_pool);
@ -737,7 +744,10 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
}
SVN_ERR(svn_wc__db_pdh_create_wcroot(wcroot,
apr_pstrdup(db->state_pool, local_abspath),
apr_pstrdup(db->state_pool,
symlink_wcroot_abspath
? symlink_wcroot_abspath
: local_abspath),
NULL, UNKNOWN_WC_ID, wc_format,
db->verify_format, db->enforce_empty_wq,
db->state_pool, scratch_pool));
@ -747,6 +757,13 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
{
const char *dir_relpath;
if (symlink_wcroot_abspath)
{
/* The WCROOT was found through a symlink pointing at the root of
* the WC. Cache the WCROOT under the symlink's path. */
local_dir_abspath = symlink_wcroot_abspath;
}
/* The subdirectory's relpath is easily computed relative to the
wcroot that we just found. */
dir_relpath = compute_relpath(*wcroot, local_dir_abspath, NULL);
@ -809,6 +826,7 @@ svn_wc__db_wcroot_parse_local_abspath(svn_wc__db_wcroot_t **wcroot,
scratch_pool));
if (resolved_kind == svn_node_dir)
{
symlink_wcroot_abspath = original_abspath;
SVN_ERR(read_link_target(&local_abspath, original_abspath,
scratch_pool));
/* This handle was opened in this function but is not going

View File

@ -143,6 +143,7 @@ run_base_remove(work_item_baton_t *wqb,
SVN_ERR(svn_wc__db_base_remove(db, local_abspath,
FALSE /* keep_as_working */,
TRUE /* queue_deletes */,
FALSE /* remove_locks */,
not_present_rev,
NULL, NULL, scratch_pool));

View File

@ -806,23 +806,6 @@ svn_cl__local_style_skip_ancestor(const char *parent_path,
const char *path,
apr_pool_t *pool);
/* Check that PATH_OR_URL1@REVISION1 is related to PATH_OR_URL2@REVISION2.
* Raise an error if not.
*
* ### Ideally we would also check that they are on different lines of
* history. That is easy in common cases, but to give a correct answer in
* general we need to know the operative revision(s) as well. For example,
* when one location is the branch point from which the other branch was
* copied.
*/
svn_error_t *
svn_cl__check_related_source_and_target(const char *path_or_url1,
const svn_opt_revision_t *revision1,
const char *path_or_url2,
const svn_opt_revision_t *revision2,
svn_client_ctx_t *ctx,
apr_pool_t *pool);
/* If the user is setting a mime-type to mark one of the TARGETS as binary,
* as determined by property name PROPNAME and value PROPVAL, then check
* whether Subversion's own binary-file detection recognizes the target as

View File

@ -453,7 +453,7 @@ static const resolver_option_t text_conflict_options[] =
-1 },
{ "df", N_("show diff"), N_("show all changes made to merged file"),
-1 },
{ "r", N_("resolved"), N_("accept merged version of file"),
{ "r", N_("mark resolved"), N_("accept merged version of file"),
svn_wc_conflict_choose_merged },
{ "", "", "", svn_wc_conflict_choose_unspecified },
{ "dc", N_("display conflict"), N_("show all conflicts "
@ -473,13 +473,13 @@ static const resolver_option_t text_conflict_options[] =
"(same) [theirs-full]"),
svn_wc_conflict_choose_theirs_full },
{ "", "", "", svn_wc_conflict_choose_unspecified },
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "m", N_("merge"), N_("use internal merge tool to resolve "
"conflict"), -1 },
{ "l", N_("launch tool"), N_("launch external tool to resolve "
"conflict [launch]"), -1 },
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "s", N_("show all options"), N_("show this list (also 'h', '?')"), -1 },
@ -489,9 +489,6 @@ static const resolver_option_t text_conflict_options[] =
/* Resolver options for a property conflict */
static const resolver_option_t prop_conflict_options[] =
{
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "mf", N_("my version"), N_("accept my version of entire file (even "
"non-conflicts) [mine-full]"),
svn_wc_conflict_choose_mine_full },
@ -501,8 +498,11 @@ static const resolver_option_t prop_conflict_options[] =
{ "dc", N_("display conflict"), N_("show conflicts in this property"), -1 },
{ "e", N_("edit property"), N_("change merged property value in an editor"
" [edit]"), -1 },
{ "r", N_("resolved"), N_("accept edited version of property"),
{ "r", N_("mark resolved"), N_("accept edited version of property"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -512,15 +512,15 @@ static const resolver_option_t prop_conflict_options[] =
/* Resolver options for an obstructued addition */
static const resolver_option_t obstructed_add_options[] =
{
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "mf", N_("my version"), N_("accept pre-existing item (ignore "
"upstream addition) [mine-full]"),
svn_wc_conflict_choose_mine_full },
{ "tf", N_("their version"), N_("accept incoming item (overwrite "
"pre-existing item) [theirs-full]"),
svn_wc_conflict_choose_theirs_full },
{ "p", N_("postpone"), N_("mark the conflict to be resolved later"
" [postpone]"),
svn_wc_conflict_choose_postpone },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -530,10 +530,10 @@ static const resolver_option_t obstructed_add_options[] =
/* Resolver options for a tree conflict */
static const resolver_option_t tree_conflict_options[] =
{
{ "r", N_("mark resolved"), N_("accept current working copy state"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("resolve the conflict later [postpone]"),
svn_wc_conflict_choose_postpone },
{ "r", N_("resolved"), N_("accept current working copy state"),
svn_wc_conflict_choose_merged },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -542,14 +542,30 @@ static const resolver_option_t tree_conflict_options[] =
static const resolver_option_t tree_conflict_options_update_moved_away[] =
{
{ "mc", N_("apply update (recommended)"),
N_("apply update to the move destination"
" [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("discard update (breaks move)"), N_("discard update, mark "
"resolved, the move will "
"will become a copy"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("resolve the conflict later [postpone]"),
svn_wc_conflict_choose_postpone },
{ "mc", N_("my side of conflict"), N_("apply update to the move destination"
" [mine-conflict]"),
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
{ NULL }
};
static const resolver_option_t tree_conflict_options_update_edit_moved_away[] =
{
{ "mc", N_("apply update to move destination"),
N_("apply incoming update to move destination"
" [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("resolved"), N_("mark resolved "
"(the move will become a copy)"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("resolve the conflict later [postpone]"),
svn_wc_conflict_choose_postpone },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -558,14 +574,14 @@ static const resolver_option_t tree_conflict_options_update_moved_away[] =
static const resolver_option_t tree_conflict_options_update_deleted[] =
{
{ "mc", N_("keep affected local moves"), N_("keep any local moves affected "
"by this deletion [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("mark resolved (breaks moves)"), N_("mark resolved, any affected "
"moves will become copies"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("resolve the conflict later [postpone]"),
svn_wc_conflict_choose_postpone },
{ "mc", N_("my side of conflict"), N_("keep any moves affected "
"by this deletion [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("resolved"), N_("mark resolved (any affected moves will "
"become copies)"),
svn_wc_conflict_choose_merged },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -574,14 +590,14 @@ static const resolver_option_t tree_conflict_options_update_deleted[] =
static const resolver_option_t tree_conflict_options_update_replaced[] =
{
{ "mc", N_("keep affected local moves"), N_("keep any moves affected by this "
"replacement [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("mark resolved (breaks moves)"), N_("mark resolved (any affected "
"moves will become copies)"),
svn_wc_conflict_choose_merged },
{ "p", N_("postpone"), N_("resolve the conflict later [postpone]"),
svn_wc_conflict_choose_postpone },
{ "mc", N_("my side of conflict"), N_("keep any moves affected by this "
"replacement [mine-conflict]"),
svn_wc_conflict_choose_mine_conflict },
{ "r", N_("resolved"), N_("mark resolved (any affected moves will "
"become copies)"),
svn_wc_conflict_choose_merged },
{ "q", N_("quit resolution"), N_("postpone all remaining conflicts"),
svn_wc_conflict_choose_postpone },
{ "h", N_("help"), N_("show this help (also '?')"), -1 },
@ -925,7 +941,7 @@ handle_text_conflict(svn_wc_conflict_result_t *result,
SVN_ERR(svn_cmdline_fprintf(
stderr, iterpool,
_("Invalid option; use diff/edit/merge/launch "
"before choosing 'resolved'.\n\n")));
"before choosing 'mark resolved'.\n\n")));
continue;
}
@ -1078,7 +1094,12 @@ handle_tree_conflict(svn_wc_conflict_result_t *result,
desc->operation == svn_wc_operation_switch)
{
if (desc->reason == svn_wc_conflict_reason_moved_away)
tc_opts = tree_conflict_options_update_moved_away;
{
if (desc->action == svn_wc_conflict_action_edit)
tc_opts = tree_conflict_options_update_edit_moved_away;
else
tc_opts = tree_conflict_options_update_moved_away;
}
else if (desc->reason == svn_wc_conflict_reason_deleted)
tc_opts = tree_conflict_options_update_deleted;
else if (desc->reason == svn_wc_conflict_reason_replaced)

View File

@ -655,6 +655,8 @@ merge_chunks(apr_array_header_t **merged_chunk,
svn_stringbuf_appendcstr(
prompt,
_("Select: (1) use their version, (2) use your version,\n"
" (12) their version first, then yours,\n"
" (21) your version first, then theirs,\n"
" (e1) edit their version and use the result,\n"
" (e2) edit your version and use the result,\n"
" (eb) edit both versions and use the result,\n"
@ -679,6 +681,24 @@ merge_chunks(apr_array_header_t **merged_chunk,
*merged_chunk = chunk2;
break;
}
if (strcmp(answer, "12") == 0)
{
*merged_chunk = apr_array_make(result_pool,
chunk1->nelts + chunk2->nelts,
sizeof(svn_stringbuf_t *));
apr_array_cat(*merged_chunk, chunk1);
apr_array_cat(*merged_chunk, chunk2);
break;
}
if (strcmp(answer, "21") == 0)
{
*merged_chunk = apr_array_make(result_pool,
chunk1->nelts + chunk2->nelts,
sizeof(svn_stringbuf_t *));
apr_array_cat(*merged_chunk, chunk2);
apr_array_cat(*merged_chunk, chunk1);
break;
}
else if (strcmp(answer, "p") == 0)
{
*merged_chunk = NULL;

View File

@ -101,15 +101,6 @@ run_merge(svn_boolean_t two_sources_specified,
&& (first_range_end.kind == svn_opt_revision_unspecified))
{
ranges_to_merge = NULL;
/* This must be a 'sync' merge so check branch relationship. */
if (opt_state->verbose)
SVN_ERR(svn_cmdline_printf(
scratch_pool, _("--- Checking branch relationship\n")));
SVN_ERR_W(svn_cl__check_related_source_and_target(
sourcepath1, &peg_revision1,
targetpath, &unspecified_revision, ctx, scratch_pool),
_("Source and target must be different but related branches"));
}
if (opt_state->verbose)

View File

@ -297,11 +297,6 @@ svn_cl__mergeinfo(apr_getopt_t *os,
tgt_peg_revision.kind = svn_opt_revision_base;
}
SVN_ERR_W(svn_cl__check_related_source_and_target(source, &src_peg_revision,
target, &tgt_peg_revision,
ctx, pool),
_("Source and target must be different but related branches"));
src_start_revision = &(opt_state->start_revision);
if (opt_state->end_revision.kind == svn_opt_revision_unspecified)
src_end_revision = src_start_revision;
@ -311,22 +306,32 @@ svn_cl__mergeinfo(apr_getopt_t *os,
/* Do the real work, depending on the requested data flavor. */
if (opt_state->show_revs == svn_cl__show_revs_merged)
{
apr_array_header_t *revprops;
/* We need only revisions number, not revision properties. */
revprops = apr_array_make(pool, 0, sizeof(const char *));
SVN_ERR(svn_client_mergeinfo_log2(TRUE, target, &tgt_peg_revision,
source, &src_peg_revision,
src_start_revision,
src_end_revision,
print_log_rev, NULL,
TRUE, depth, NULL, ctx,
TRUE, depth, revprops, ctx,
pool));
}
else if (opt_state->show_revs == svn_cl__show_revs_eligible)
{
apr_array_header_t *revprops;
/* We need only revisions number, not revision properties. */
revprops = apr_array_make(pool, 0, sizeof(const char *));
SVN_ERR(svn_client_mergeinfo_log2(FALSE, target, &tgt_peg_revision,
source, &src_peg_revision,
src_start_revision,
src_end_revision,
print_log_rev, NULL,
TRUE, depth, NULL, ctx,
TRUE, depth, revprops, ctx,
pool));
}
else

View File

@ -484,9 +484,19 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
{'r', 'q', 'N', opt_depth, opt_force, opt_ignore_externals} },
{ "cleanup", svn_cl__cleanup, {0}, N_
("Recursively clean up the working copy, removing locks, resuming\n"
("Recursively clean up the working copy, removing write locks, resuming\n"
"unfinished operations, etc.\n"
"usage: cleanup [WCPATH...]\n"),
"usage: cleanup [WCPATH...]\n"
"\n"
" Finish any unfinished business in the working copy at WCPATH, and remove\n"
" write locks (shown as 'L' by the 'svn status' command) from the working\n"
" copy. Usually, this is only necessary if a Subversion client has crashed\n"
" while using the working copy, leaving it in an unusable state.\n"
"\n"
" WARNING: There is no mechanism that will protect write locks still\n"
" being used by other Subversion clients. Running this command\n"
" while another client is using the working copy can corrupt\n"
" the working copy beyond repair!\n"),
{opt_merge_cmd} },
{ "commit", svn_cl__commit, {"ci"},
@ -750,18 +760,18 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
* (with quotes and newlines removed). */
"Merge changes into a working copy.\n"
"usage: 1. merge SOURCE[@REV] [TARGET_WCPATH]\n"
" (the 'automatic' merge)\n"
" (the 'complete' merge)\n"
" 2. merge [-c M[,N...] | -r N:M ...] SOURCE[@REV] [TARGET_WCPATH]\n"
" (the 'cherry-pick' merge)\n"
" 3. merge SOURCE1[@REV1] SOURCE2[@REV2] [TARGET_WCPATH]\n"
" (the '2-URL' merge)\n"
"\n"
" 1. This form, with one source path and no revision range, is called\n"
" an 'automatic' merge:\n"
" a 'complete' merge:\n"
"\n"
" svn merge SOURCE[@REV] [TARGET_WCPATH]\n"
"\n"
" The automatic merge is used for the 'sync' and 'reintegrate' merges\n"
" The complete merge is used for the 'sync' and 'reintegrate' merges\n"
" in the 'feature branch' pattern described below. It finds all the\n"
" changes on the source branch that have not already been merged to the\n"
" target branch, and merges them into the working copy. Merge tracking\n"
@ -900,7 +910,7 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
" of 'REV' is the base revision (usually the revision last updated to).\n"
"\n"
" TARGET_WCPATH is a working copy path; if omitted, '.' is generally\n"
" assumed. The special cases noted above in the 'automatic' merge form\n"
" assumed. The special cases noted above in the 'complete' merge form\n"
" also apply here.\n"
"\n"
" The revision ranges to be merged are specified by the '-r' and/or '-c'\n"
@ -971,7 +981,7 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
" The three branches involved can be completely unrelated.\n"
"\n"
" TARGET_WCPATH is a working copy path; if omitted, '.' is generally\n"
" assumed. The special cases noted above in the 'automatic' merge form\n"
" assumed. The special cases noted above in the 'complete' merge form\n"
" also apply here.\n"
"\n"
" SOURCE1 and/or SOURCE2 can also be specified as a working copy path,\n"
@ -1088,7 +1098,7 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
" shows, from left to right:\n"
" the youngest common ancestor of the branches;\n"
" the latest full merge in either direction, and thus the common base\n"
" that will be used for the next automatic merge;\n"
" that will be used for the next complete merge;\n"
" the repository path and revision number of the tip of each branch.\n"
"\n"
" 2. Print the revision numbers on SOURCE that have been merged to TARGET\n"
@ -1430,9 +1440,10 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
" ' ' no modifications\n"
" 'C' Conflicted\n"
" 'M' Modified\n"
" Third column: Whether the working copy directory is locked\n"
" ' ' not locked\n"
" 'L' locked\n"
" Third column: Whether the working copy is locked for writing by\n"
" another Subversion client modifying the working copy\n"
" ' ' not locked for writing\n"
" 'L' locked for writing\n"
" Fourth column: Scheduled commit will contain addition-with-history\n"
" ' ' no history scheduled with commit\n"
" '+' history scheduled with commit\n"
@ -1440,16 +1451,16 @@ const svn_opt_subcommand_desc2_t svn_cl__cmd_table[] =
" ' ' normal\n"
" 'S' the item has a Switched URL relative to the parent\n"
" 'X' a versioned file created by an eXternals definition\n"
" Sixth column: Repository lock token\n"
" Sixth column: Whether the item is locked in repository for exclusive commit\n"
" (without -u)\n"
" ' ' no lock token\n"
" 'K' lock token present\n"
" ' ' not locked by this working copy\n"
" 'K' locked by this working copy, but lock might be stolen or broken\n"
" (with -u)\n"
" ' ' not locked in repository, no lock token\n"
" 'K' locked in repository, lock toKen present\n"
" 'O' locked in repository, lock token in some Other working copy\n"
" 'T' locked in repository, lock token present but sTolen\n"
" 'B' not locked in repository, lock token present but Broken\n"
" ' ' not locked in repository, not locked by this working copy\n"
" 'K' locked in repository, lock owned by this working copy\n"
" 'O' locked in repository, lock owned by another working copy\n"
" 'T' locked in repository, lock owned by this working copy was stolen\n"
" 'B' not locked in repository, lock owned by this working copy is broken\n"
" Seventh column: Whether the item is the victim of a tree conflict\n"
" ' ' normal\n"
" 'C' tree-Conflicted\n"

View File

@ -1012,46 +1012,6 @@ svn_cl__local_style_skip_ancestor(const char *parent_path,
return svn_dirent_local_style(relpath ? relpath : path, pool);
}
/* Return a string of the form "PATH_OR_URL@REVISION". */
static const char *
path_for_display(const char *path_or_url,
const svn_opt_revision_t *revision,
apr_pool_t *pool)
{
const char *rev_str = svn_opt__revision_to_string(revision, pool);
if (! svn_path_is_url(path_or_url))
path_or_url = svn_dirent_local_style(path_or_url, pool);
return apr_psprintf(pool, "%s@%s", path_or_url, rev_str);
}
svn_error_t *
svn_cl__check_related_source_and_target(const char *path_or_url1,
const svn_opt_revision_t *revision1,
const char *path_or_url2,
const svn_opt_revision_t *revision2,
svn_client_ctx_t *ctx,
apr_pool_t *pool)
{
const char *ancestor_url;
svn_revnum_t ancestor_rev;
SVN_ERR(svn_client__youngest_common_ancestor(
&ancestor_url, &ancestor_rev,
path_or_url1, revision1, path_or_url2, revision2,
ctx, pool, pool));
if (ancestor_url == NULL)
{
return svn_error_createf(SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
_("Source and target have no common ancestor: "
"'%s' and '%s'"),
path_for_display(path_or_url1, revision1, pool),
path_for_display(path_or_url2, revision2, pool));
}
return SVN_NO_ERROR;
}
svn_error_t *
svn_cl__propset_print_binary_mime_type_warning(apr_array_header_t *targets,
const char *propname,

View File

@ -685,6 +685,18 @@ subcommand_create(apr_getopt_t *os, void *baton, apr_pool_t *pool)
svn_hash_sets(fs_config, SVN_FS_CONFIG_PRE_1_8_COMPATIBLE, "1");
}
if (opt_state->compatible_version
&& ! svn_version__at_least(opt_state->compatible_version, 1, 1, 0)
/* ### TODO: this NULL check hard-codes knowledge of the library's
default fs-type value */
&& (opt_state->fs_type == NULL
|| !strcmp(opt_state->fs_type, SVN_FS_TYPE_FSFS)))
{
return svn_error_create(SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
_("Repositories compatible with 1.0.x must use "
"--fs-type=bdb"));
}
SVN_ERR(svn_repos_create(&repos, opt_state->repository_path,
NULL, NULL, NULL, fs_config, pool));
svn_fs_set_warning_func(svn_repos_fs(repos), warning_func, NULL);

View File

@ -57,6 +57,7 @@
#include "private/svn_diff_private.h"
#include "private/svn_cmdline_private.h"
#include "private/svn_fspath.h"
#include "private/svn_io_private.h"
#include "svn_private_config.h"
@ -983,12 +984,21 @@ print_diff_tree(svn_stream_t *out_stream,
SVN_ERR(generate_label(&new_label, root, path, pool));
/* We deal in streams, but svn_io_run_diff2() deals in file
handles, unfortunately, so we need to make these temporary
files, and then copy the contents to our stream. */
SVN_ERR(svn_io_open_unique_file3(&outfile, &outfilename, NULL,
svn_io_file_del_on_pool_cleanup, pool, pool));
SVN_ERR(svn_io_open_unique_file3(&errfile, &errfilename, NULL,
svn_io_file_del_on_pool_cleanup, pool, pool));
handles, so we may need to make temporary files and then
copy the contents to our stream. */
outfile = svn_stream__aprfile(out_stream);
if (outfile)
outfilename = NULL;
else
SVN_ERR(svn_io_open_unique_file3(&outfile, &outfilename, NULL,
svn_io_file_del_on_pool_cleanup, pool, pool));
SVN_ERR(svn_stream_for_stderr(&err_stream, pool));
errfile = svn_stream__aprfile(err_stream);
if (errfile)
errfilename = NULL;
else
SVN_ERR(svn_io_open_unique_file3(&errfile, &errfilename, NULL,
svn_io_file_del_on_pool_cleanup, pool, pool));
SVN_ERR(svn_io_run_diff2(".",
diff_cmd_argv,
@ -998,21 +1008,25 @@ print_diff_tree(svn_stream_t *out_stream,
&exitcode, outfile, errfile,
c->diff_cmd, pool));
SVN_ERR(svn_io_file_close(outfile, pool));
SVN_ERR(svn_io_file_close(errfile, pool));
/* Now, open and copy our files to our output streams. */
SVN_ERR(svn_stream_for_stderr(&err_stream, pool));
SVN_ERR(svn_stream_open_readonly(&stream, outfilename,
pool, pool));
SVN_ERR(svn_stream_copy3(stream,
svn_stream_disown(out_stream, pool),
NULL, NULL, pool));
SVN_ERR(svn_stream_open_readonly(&stream, errfilename,
pool, pool));
SVN_ERR(svn_stream_copy3(stream,
svn_stream_disown(err_stream, pool),
NULL, NULL, pool));
if (outfilename)
{
SVN_ERR(svn_io_file_close(outfile, pool));
SVN_ERR(svn_stream_open_readonly(&stream, outfilename,
pool, pool));
SVN_ERR(svn_stream_copy3(stream,
svn_stream_disown(out_stream, pool),
NULL, NULL, pool));
}
if (errfilename)
{
SVN_ERR(svn_io_file_close(errfile, pool));
SVN_ERR(svn_stream_open_readonly(&stream, errfilename,
pool, pool));
SVN_ERR(svn_stream_copy3(stream,
svn_stream_disown(err_stream, pool),
NULL, NULL, pool));
}
SVN_ERR(svn_stream_printf_from_utf8(out_stream, encoding, pool,
"\n"));

View File

@ -1441,6 +1441,7 @@ static svn_error_t *commit(svn_ra_svn_conn_t *conn, apr_pool_t *pool,
if (lock_tokens && lock_tokens->nelts)
SVN_CMD_ERR(add_lock_tokens(conn, lock_tokens, b, pool));
/* Ignore LOG_MSG, per the protocol. See ra_svn_commit(). */
if (revprop_list)
SVN_ERR(svn_ra_svn__parse_proplist(revprop_list, pool, &revprop_table));
else

View File

@ -25,7 +25,7 @@
"""
# $HeadURL: http://svn.apache.org/repos/asf/subversion/branches/1.8.x/win-tests.py $
# $LastChangedRevision: 1467191 $
# $LastChangedRevision: 1492044 $
import os, sys, subprocess
import filecmp
@ -600,6 +600,12 @@ def _create_mime_types_file(self):
def _create_dontdothat_file(self):
"Create empty mime.types file"
# If the tests have not previously been run or were cleaned
# up, then 'svn-test-work' does not exist yet.
parent_dir = os.path.dirname(self.dontdothat_file)
if not os.path.exists(parent_dir):
os.makedirs(parent_dir)
fp = open(self.dontdothat_file, 'w')
fp.write('[recursive-actions]\n')
fp.write('/ = deny\n')