You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2015/11/30 11:24:23 UTC
svn commit: r1717223 [7/50] - in /subversion/branches/ra-git: ./ build/
build/ac-macros/ build/generator/ build/generator/templates/
contrib/hook-scripts/ notes/ notes/api-errata/1.9/ notes/move-tracking/
subversion/ subversion/bindings/ctypes-python/c...
Modified: subversion/branches/ra-git/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNTests.java
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNTests.java?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNTests.java (original)
+++ subversion/branches/ra-git/subversion/bindings/javahl/tests/org/apache/subversion/javahl/SVNTests.java Mon Nov 30 10:24:16 2015
@@ -80,6 +80,17 @@ class SVNTests extends TestCase
protected static int testCounter;
/**
+ * Set to true if tests should clean up after themselves.
+ */
+ protected boolean cleanupAfterTests = false;
+
+ /**
+ * this list contains the names of all repository and working copy
+ * directories created by one test case.
+ */
+ protected static List<File> testDirs;
+
+ /**
* the file in which the sample repository has been dumped.
*/
protected File greekDump;
@@ -173,6 +184,10 @@ class SVNTests extends TestCase
private void init()
{
+ String cleanupProp = System.getProperty("test.cleanup");
+ if (cleanupProp != null)
+ cleanupAfterTests = (0 < cleanupProp.trim().length());
+
String disableCredStore = System.getProperty("test.disablecredstore");
if (disableCredStore != null)
{
@@ -510,6 +525,16 @@ class SVNTests extends TestCase
client.dispose();
// remove the temporary directory
removeDirOrFile(localTmp);
+
+ // optionally remove the test directories
+ List<File> td = testDirs;
+ testDirs = null;
+ if (cleanupAfterTests && td != null)
+ {
+ for(File f: td)
+ removeDirOrFile(f);
+ }
+
super.tearDown();
}
@@ -788,6 +813,13 @@ class SVNTests extends TestCase
return wc;
}
+ private void trackDir(File dir)
+ {
+ if (testDirs == null)
+ testDirs = new ArrayList<File>();
+ testDirs.add(dir);
+ }
+
/**
* Create the repository for the beginning of the test.
* Assumes that {@link #testName} has been set.
@@ -804,6 +836,7 @@ class SVNTests extends TestCase
// build a clean repository directory
File repos = new File(repositories, this.testName);
removeDirOrFile(repos);
+ trackDir(repos);
// create and load the repository from the default repository dump
admin.create(repos, true, false, conf, fsType);
if (loadGreek)
@@ -829,6 +862,7 @@ class SVNTests extends TestCase
URI uri = makeReposUrl(repos);
workingCopy = new File(workingCopies, this.testName);
removeDirOrFile(workingCopy);
+ trackDir(workingCopy);
// checkout the repository
client.checkout(uri.toString(), workingCopy.getAbsolutePath(),
null, null, Depth.infinity, false, false);
Modified: subversion/branches/ra-git/subversion/bindings/javahl/tests/org/tigris/subversion/javahl/SVNAdminTests.java
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/javahl/tests/org/tigris/subversion/javahl/SVNAdminTests.java?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/javahl/tests/org/tigris/subversion/javahl/SVNAdminTests.java (original)
+++ subversion/branches/ra-git/subversion/bindings/javahl/tests/org/tigris/subversion/javahl/SVNAdminTests.java Mon Nov 30 10:24:16 2015
@@ -35,13 +35,33 @@ import org.tigris.subversion.javahl.Subv
*/
public class SVNAdminTests extends SVNTests
{
+ /**
+ * Base name of all our tests.
+ */
+ public final static String testName = "admin_test";
+
public SVNAdminTests()
{
+ init();
}
public SVNAdminTests(String name)
{
super(name);
+ init();
+ }
+
+ /**
+ * Initialize the testBaseName and the testCounter, if this is the
+ * first test of this class.
+ */
+ private void init()
+ {
+ if (!testName.equals(testBaseName))
+ {
+ testCounter = 0;
+ testBaseName = testName;
+ }
}
/**
Modified: subversion/branches/ra-git/subversion/bindings/swig/INSTALL
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/INSTALL?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/INSTALL (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/INSTALL Mon Nov 30 10:24:16 2015
@@ -65,7 +65,7 @@ BUILDING SWIG BINDINGS FOR SVN ON UNIX
Step 1: Install a suitable version of SWIG (which is
- currently SWIG version 1.3.24 or later).
+ currently SWIG version 1.3.24 or later, but not SWIG 3.0.0 or newer).
* Perhaps your distribution packages a suitable version - if it does
install it, and skip to the last bullet point in this section.
@@ -80,7 +80,7 @@ Step 1: Install a suitable version of S
--with-python=/path/to/correct/python/binary
- to the configure script. You need Python 2.5 or above.
+ to the configure script. You need Python 2.7 or above.
If you plan to build the Perl bindings, and have a system
with more than one version of perl installed, you may need
@@ -109,7 +109,7 @@ Step 2: Build and Install Subversion.
python executable you used to configure SWIG as above. If it does not then
you can specify the correct path by adding PYTHON=/path/to/python or
PERL=/path/to/perl onto the command line for configure. For example:
- ./configure PYTHON=/usr/bin/python2.5 PERL=/usr/bin/perl5.8.0
+ ./configure PYTHON=/usr/bin/python2.7 PERL=/usr/bin/perl5.8.0
If Subversion's ./configure finds a SWIG that it's happy with, then
it will build special glue libraries to link svn to the swig bindings:
Modified: subversion/branches/ra-git/subversion/bindings/swig/core.i
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/core.i?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/core.i (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/core.i Mon Nov 30 10:24:16 2015
@@ -532,8 +532,10 @@
$1 = NULL;
}
else if (SvPOK($input)) {
- if (_global_pool == NULL)
+ if (_global_pool == NULL) {
_global_pool = svn_swig_pl_make_pool((SV *)NULL);
+ SPAGAIN;
+ }
$1 = apr_pstrdup(_global_pool, SvPV_nolen($input));
}
else {
@@ -836,6 +838,7 @@ core_set_current_pool (apr_pool_t *pool)
%include svn_mergeinfo_h.swg
%include svn_io_h.swg
%include svn_checksum_h.swg
+%include svn_cache_config_h.swg
Modified: subversion/branches/ra-git/subversion/bindings/swig/include/apr.swg
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/include/apr.swg?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/include/apr.swg (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/include/apr.swg Mon Nov 30 10:24:16 2015
@@ -31,23 +31,21 @@
*/
#ifdef SWIGPERL
%typemap(out) long long {
- char temp[256];
+ char temp[30];
sprintf(temp, "%" APR_INT64_T_FMT, (apr_int64_t) $1);
- ST(argvi) = sv_newmortal();
- sv_setpv((SV*)ST(argvi++), temp);
+ %append_output(sv_2mortal(newSVpv(temp, 0)));
}
%typemap(out) unsigned long long {
- char temp[256];
+ char temp[30];
sprintf(temp, "%" APR_UINT64_T_FMT, (apr_uint64_t) $1);
- ST(argvi) = sv_newmortal();
- sv_setpv((SV*)ST(argvi++), temp);
+ %append_output(sv_2mortal(newSVpv(temp, 0)));
}
%typemap(in, numinputs=0) long long *OUTPUT (apr_int64_t temp)
"$1 = &temp;";
%typemap(argout) long long *OUTPUT {
- char temp[256];
+ char temp[30];
sprintf(temp, "%" APR_INT64_T_FMT, (apr_int64_t)*($1));
%append_output(sv_2mortal(newSVpv(temp, 0)));
}
@@ -55,7 +53,7 @@
%typemap(in, numinputs=0) unsigned long long *OUTPUT (apr_uint64_t temp)
"$1 = &temp;";
%typemap(argout) unsigned long long *OUTPUT {
- char temp[256];
+ char temp[30];
sprintf(temp, "%" APR_UINT64_T_FMT, (apr_uint64_t)*($1));
%append_output(sv_2mortal(newSVpv(temp, 0)));
}
Modified: subversion/branches/ra-git/subversion/bindings/swig/include/svn_containers.swg
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/include/svn_containers.swg?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/include/svn_containers.swg (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/include/svn_containers.swg Mon Nov 30 10:24:16 2015
@@ -269,8 +269,10 @@
%typemap(in) apr_hash_t *PROPHASH
(apr_pool_t *_global_pool = NULL)
{
- if (_global_pool == NULL)
+ if (_global_pool == NULL) {
_global_pool = svn_swig_pl_make_pool((SV *)NULL);
+ SPAGAIN;
+ }
$1 = svn_swig_pl_hash_to_prophash($input, _global_pool);
}
%typemap(out) apr_hash_t *PROPHASH
Modified: subversion/branches/ra-git/subversion/bindings/swig/include/svn_string.swg
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/include/svn_string.swg?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/include/svn_string.swg (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/include/svn_string.swg Mon Nov 30 10:24:16 2015
@@ -90,6 +90,7 @@ typedef struct svn_string_t svn_string_t
%typemap(in) svn_stringbuf_t * {
apr_size_t len;
char *buf;
+ apr_pool_t *pool;
if (!SvOK($input)) {
$1 = NULL;
@@ -97,8 +98,9 @@ typedef struct svn_string_t svn_string_t
buf = SvPV($input, len);
/* Another case of ugly pool handling, this should use the current
default pool, or make a new one if it doesn't exist yet */
- $1 = svn_stringbuf_ncreate(buf,len,
- svn_swig_pl_make_pool ((SV *)NULL));
+ pool = svn_swig_pl_make_pool ((SV *)NULL);
+ SPAGAIN;
+ $1 = svn_stringbuf_ncreate(buf,len, pool);
} else {
croak("Not a string");
}
Modified: subversion/branches/ra-git/subversion/bindings/swig/include/svn_types.swg
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/include/svn_types.swg?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/include/svn_types.swg (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/include/svn_types.swg Mon Nov 30 10:24:16 2015
@@ -69,6 +69,15 @@
#endif
}
+%typemap(in,warning="901:FIXME: Missing old_value_p typemap") const svn_string_t *const *old_value_p {
+#if defined(SWIGRUBY) && SWIG_VERSION <= 0x010329
+ /* Ruby fails to define $symname. */
+ SWIG_exception(SWIG_ValueError, "Function is not implemented yet");
+#else
+ SWIG_exception(SWIG_ValueError, "$symname is not implemented yet");
+#endif
+}
+
#ifdef SWIGPYTHON
%typemap(argout) SWIGTYPE **OUTPARAM {
%append_output(svn_swig_py_new_pointer_obj(*$1, $*1_descriptor,
@@ -423,9 +432,11 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
if (SvOK(exception_handler)) {
SV *callback_result;
+ PUTBACK;
svn_swig_pl_callback_thunk (CALL_SV, exception_handler,
&callback_result, "S", $1,
$1_descriptor);
+ SPAGAIN;
} else {
$result = SWIG_NewPointerObj($1, $1_descriptor, 0);
argvi++;
@@ -548,6 +559,7 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
%typemap(in) apr_pool_t *pool "";
%typemap(default) apr_pool_t *pool(apr_pool_t *_global_pool) {
_global_pool = $1 = svn_swig_pl_make_pool (ST(items-1));
+ SPAGAIN;
}
#endif
#ifdef SWIGRUBY
@@ -935,15 +947,24 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
#ifdef SWIGPERL
%typemap(in) svn_stream_t * {
svn_swig_pl_make_stream (&$1, $input);
+ SPAGAIN;
}
%typemap(out) svn_stream_t * {
- $result = svn_swig_pl_from_stream ($1);
+ SV* tmp;
+ PUTBACK;
+ tmp = svn_swig_pl_from_stream ($1);
+ SPAGAIN;
+ $result = tmp;
argvi++;
}
%typemap(argout) svn_stream_t ** {
- %append_output(svn_swig_pl_from_stream(*$1));
+ SV *tmp;
+ PUTBACK;
+ tmp = svn_swig_pl_from_stream(*$1);
+ SPAGAIN;
+ %append_output(tmp);
}
#endif
@@ -1116,11 +1137,11 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
}
%typemap(argout) unsigned char *result_digest {
- /* FIXME: This code is clearly buggy. The return value of sv_newmortal()
- is immediately overwritten by the return value
- of svn_swig_pl_from_md5(). */
- ST(argvi) = sv_newmortal();
- ST(argvi++) = svn_swig_pl_from_md5($1);
+ SV *tmp;
+ PUTBACK;
+ tmp = svn_swig_pl_from_md5($1);
+ SPAGAIN;
+ %append_output(tmp);
}
#endif
@@ -1140,6 +1161,7 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
#endif
#ifdef SWIGPYTHON
+/* ### Verify if this should use '[]' like perl and ruby */
%typemap(in) const unsigned char *digest {
if ($input == Py_None) {
$1 = NULL;
@@ -1151,7 +1173,7 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
#endif
#ifdef SWIGRUBY
-%typemap(in) const unsigned char *digest
+%typemap(in) const unsigned char digest[]
{
if (NIL_P($input)) {
$1 = NULL;
@@ -1174,8 +1196,10 @@ svn_ ## TYPE ## _swig_rb_closed(VALUE se
%typemap(in) svn_opt_revision_t *
(svn_opt_revision_t rev, apr_pool_t *_global_pool = NULL)
{
- if (_global_pool == NULL)
+ if (_global_pool == NULL) {
_global_pool = svn_swig_pl_make_pool((SV *)NULL);
+ SPAGAIN;
+ }
$1 = svn_swig_pl_set_revision(&rev, $input, TRUE, _global_pool);
}
#endif
Modified: subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.c Mon Nov 30 10:24:16 2015
@@ -520,6 +520,7 @@ svn_opt_revision_t *svn_swig_pl_set_revi
put returned value in result if result is not NULL
*/
+/* NOTE: calls back into Perl (directly) */
svn_error_t *svn_swig_pl_callback_thunk(perl_func_invoker_t caller_func,
void *func,
SV **result,
@@ -670,6 +671,7 @@ static item_baton * make_baton(apr_pool_
return newb;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * close_baton(void *baton, const char *method, apr_pool_t *pool)
{
item_baton *ib = baton;
@@ -690,6 +692,7 @@ static svn_error_t * close_baton(void *b
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_set_target_revision(void *edit_baton,
svn_revnum_t target_revision,
apr_pool_t *pool)
@@ -703,6 +706,7 @@ static svn_error_t * thunk_set_target_re
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_open_root(void *edit_baton,
svn_revnum_t base_revision,
apr_pool_t *dir_pool,
@@ -720,6 +724,7 @@ static svn_error_t * thunk_open_root(voi
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_delete_entry(const char *path,
svn_revnum_t revision,
void *parent_baton,
@@ -734,6 +739,7 @@ static svn_error_t * thunk_delete_entry(
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_add_directory(const char *path,
void *parent_baton,
const char *copyfrom_path,
@@ -753,6 +759,7 @@ static svn_error_t * thunk_add_directory
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_open_directory(const char *path,
void *parent_baton,
svn_revnum_t base_revision,
@@ -772,6 +779,7 @@ static svn_error_t * thunk_open_director
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_change_dir_prop(void *dir_baton,
const char *name,
const svn_string_t *value,
@@ -787,12 +795,14 @@ static svn_error_t * thunk_change_dir_pr
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling close_baton) */
static svn_error_t * thunk_close_directory(void *dir_baton,
apr_pool_t *pool)
{
return close_baton(dir_baton, "close_directory", pool);
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_absent_directory(const char *path,
void *parent_baton,
apr_pool_t *pool)
@@ -807,6 +817,7 @@ static svn_error_t * thunk_absent_direct
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_add_file(const char *path,
void *parent_baton,
const char *copyfrom_path,
@@ -827,6 +838,7 @@ static svn_error_t * thunk_add_file(cons
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_open_file(const char *path,
void *parent_baton,
svn_revnum_t base_revision,
@@ -845,6 +857,7 @@ static svn_error_t * thunk_open_file(con
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_window_handler(svn_txdelta_window_t *window,
void *baton)
{
@@ -865,6 +878,7 @@ static svn_error_t * thunk_window_handle
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t *
thunk_apply_textdelta(void *file_baton,
const char *base_checksum,
@@ -909,6 +923,7 @@ thunk_apply_textdelta(void *file_baton,
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_change_file_prop(void *file_baton,
const char *name,
const svn_string_t *value,
@@ -924,6 +939,7 @@ static svn_error_t * thunk_change_file_p
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_close_file(void *file_baton,
const char *text_checksum,
apr_pool_t *pool)
@@ -940,6 +956,7 @@ static svn_error_t * thunk_close_file(vo
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_absent_file(const char *path,
void *parent_baton,
apr_pool_t *pool)
@@ -954,12 +971,14 @@ static svn_error_t * thunk_absent_file(c
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling close_baton) */
static svn_error_t * thunk_close_edit(void *edit_baton,
apr_pool_t *pool)
{
return close_baton(edit_baton, "close_edit", pool);
}
+/* NOTE: calls back into Perl (by calling close_baton) */
static svn_error_t * thunk_abort_edit(void *edit_baton,
apr_pool_t *pool)
{
@@ -967,18 +986,6 @@ static svn_error_t * thunk_abort_edit(vo
}
-void
-svn_swig_pl_wrap_window_handler(svn_txdelta_window_handler_t *handler,
- void **h_baton,
- SV *callback,
- apr_pool_t *pool)
-{
- *handler = thunk_window_handler;
- *h_baton = callback;
- SvREFCNT_inc(callback);
- svn_swig_pl_hold_ref_in_pool(pool, callback);
-}
-
void svn_swig_pl_make_editor(svn_delta_editor_t **editor,
void **edit_baton,
SV *perl_editor,
@@ -1008,6 +1015,7 @@ void svn_swig_pl_make_editor(svn_delta_e
svn_swig_pl_hold_ref_in_pool(pool, perl_editor);
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_log_receiver(void *baton,
apr_hash_t *changed_paths,
svn_revnum_t rev,
@@ -1032,6 +1040,7 @@ svn_error_t *svn_swig_pl_thunk_log_recei
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_log_entry_receiver(void *baton,
svn_log_entry_t *log_entry,
apr_pool_t *pool)
@@ -1050,6 +1059,7 @@ svn_error_t *svn_swig_pl_thunk_log_entry
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t * svn_swig_pl_thunk_client_diff_summarize_func(
const svn_client_diff_summarize_t *diff,
void *baton,
@@ -1069,6 +1079,7 @@ svn_error_t * svn_swig_pl_thunk_client_d
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_history_func(void *baton,
const char *path,
svn_revnum_t revision,
@@ -1086,6 +1097,7 @@ svn_error_t *svn_swig_pl_thunk_history_f
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_authz_func(svn_boolean_t *allowed,
svn_fs_root_t *root,
const char *path,
@@ -1108,6 +1120,7 @@ svn_error_t *svn_swig_pl_thunk_authz_fun
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_commit_callback(svn_revnum_t new_revision,
const char *date,
const char *author,
@@ -1122,6 +1135,7 @@ svn_error_t *svn_swig_pl_thunk_commit_ca
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_commit_callback2(const svn_commit_info_t *commit_info,
void *baton,
apr_pool_t *pool)
@@ -1140,6 +1154,7 @@ svn_error_t *svn_swig_pl_thunk_commit_ca
/* Wrap RA */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t * thunk_open_tmp_file(apr_file_t **fp,
void *callback_baton,
apr_pool_t *pool)
@@ -1158,11 +1173,12 @@ static svn_error_t * thunk_open_tmp_file
return SVN_NO_ERROR;
}
-svn_error_t *thunk_get_wc_prop(void *baton,
- const char *relpath,
- const char *name,
- const svn_string_t **value,
- apr_pool_t *pool)
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
+static svn_error_t *thunk_get_wc_prop(void *baton,
+ const char *relpath,
+ const char *name,
+ const svn_string_t **value,
+ apr_pool_t *pool)
{
SV *result;
char *data;
@@ -1215,6 +1231,7 @@ svn_error_t *svn_swig_pl_make_callbacks(
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_gnome_keyring_unlock_prompt(char **keyring_password,
const char *keyring_name,
void *baton,
@@ -1243,6 +1260,7 @@ svn_error_t *svn_swig_pl_thunk_gnome_key
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_simple_prompt(svn_auth_cred_simple_t **cred,
void *baton,
const char *realm,
@@ -1264,6 +1282,7 @@ svn_error_t *svn_swig_pl_thunk_simple_pr
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_username_prompt(svn_auth_cred_username_t **cred,
void *baton,
const char *realm,
@@ -1284,6 +1303,7 @@ svn_error_t *svn_swig_pl_thunk_username_
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_ssl_server_trust_prompt(
svn_auth_cred_ssl_server_trust_t **cred,
void *baton,
@@ -1318,6 +1338,7 @@ svn_error_t *svn_swig_pl_thunk_ssl_serve
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_ssl_client_cert_prompt(
svn_auth_cred_ssl_client_cert_t **cred,
void *baton,
@@ -1339,6 +1360,7 @@ svn_error_t *svn_swig_pl_thunk_ssl_clien
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_thunk_ssl_client_cert_pw_prompt(
svn_auth_cred_ssl_client_cert_pw_t **cred,
void *baton,
@@ -1361,6 +1383,7 @@ svn_error_t *svn_swig_pl_thunk_ssl_clien
}
/* Thunked version of svn_wc_notify_func_t callback type */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
void svn_swig_pl_notify_func(void * baton,
const char *path,
svn_wc_notify_action_t action,
@@ -1382,6 +1405,7 @@ void svn_swig_pl_notify_func(void * bato
}
/* Thunked version of svn_client_get_commit_log3_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_get_commit_log_func(const char **log_msg,
const char **tmp_file,
const apr_array_header_t *
@@ -1444,6 +1468,7 @@ svn_error_t *svn_swig_pl_get_commit_log_
}
/* Thunked version of svn_client_info_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_info_receiver(void *baton,
const char *path,
const svn_info_t *info,
@@ -1475,6 +1500,7 @@ svn_error_t *svn_swig_pl_info_receiver(v
/* Thunked version of svn_wc_cancel_func_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_cancel_func(void *cancel_baton) {
SV *result;
svn_error_t *ret_val;
@@ -1504,6 +1530,7 @@ svn_error_t *svn_swig_pl_cancel_func(voi
}
/* Thunked version of svn_wc_status_func_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
void svn_swig_pl_status_func(void *baton,
const char *path,
svn_wc_status_t *status)
@@ -1520,6 +1547,7 @@ void svn_swig_pl_status_func(void *baton
}
/* Thunked version of svn_wc_status_func2_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
void svn_swig_pl_status_func2(void *baton,
const char *path,
svn_wc_status2_t *status)
@@ -1536,6 +1564,7 @@ void svn_swig_pl_status_func2(void *bato
}
/* Thunked version of svn_wc_status_func3_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_status_func3(void *baton,
const char *path,
svn_wc_status2_t *status,
@@ -1568,6 +1597,7 @@ svn_error_t *svn_swig_pl_status_func3(vo
/* Thunked version of svn_client_blame_receiver_t callback type. */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_blame_func(void *baton,
apr_int64_t line_no,
svn_revnum_t revision,
@@ -1596,6 +1626,7 @@ svn_error_t *svn_swig_pl_blame_func(void
}
/* Thunked config enumerator */
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_boolean_t svn_swig_pl_thunk_config_enumerator(const char *name, const char *value, void *baton)
{
SV *result;
@@ -1639,6 +1670,7 @@ void svn_swig_pl_set_current_pool(apr_po
set_current_pool_cb(pool);
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
apr_pool_t *svn_swig_pl_make_pool(SV *obj)
{
apr_pool_t *pool;
@@ -1667,6 +1699,7 @@ typedef struct io_baton_t {
IO *io;
} io_baton_t;
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t *io_handle_read(void *baton,
char *buffer,
apr_size_t *len)
@@ -1690,6 +1723,7 @@ static svn_error_t *io_handle_read(void
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t *io_handle_write(void *baton,
const char *data,
apr_size_t *len)
@@ -1710,6 +1744,7 @@ static svn_error_t *io_handle_write(void
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
static svn_error_t *io_handle_close(void *baton)
{
io_baton_t *io = baton;
@@ -1733,6 +1768,7 @@ static apr_status_t io_handle_cleanup(vo
return APR_SUCCESS;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_make_stream(svn_stream_t **stream, SV *obj)
{
IO *io;
@@ -1778,6 +1814,7 @@ svn_error_t *svn_swig_pl_make_stream(svn
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
svn_error_t *svn_swig_pl_ra_lock_callback(
void *baton,
const char *path,
@@ -1797,6 +1834,7 @@ svn_error_t *svn_swig_pl_ra_lock_callbac
return SVN_NO_ERROR;
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
SV *svn_swig_pl_from_stream(svn_stream_t *stream)
{
SV *ret;
@@ -1848,6 +1886,7 @@ void svn_swig_pl_hold_ref_in_pool(apr_po
apr_pool_cleanup_register(pool, sv, cleanup_refcnt, apr_pool_cleanup_null);
}
+/* NOTE: calls back into Perl (by calling svn_swig_pl_callback_thunk) */
SV *svn_swig_pl_from_md5(unsigned char *digest)
{
SV *ret;
Modified: subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/perl/libsvn_swig_perl/swigutil_pl.h Mon Nov 30 10:24:16 2015
@@ -209,13 +209,6 @@ svn_error_t *svn_swig_pl_thunk_ssl_clien
svn_boolean_t may_save,
apr_pool_t *pool);
-/* thunked callback for svn_ra_get_wc_prop_func_t */
-svn_error_t *thunk_get_wc_prop(void *baton,
- const char *relpath,
- const char *name,
- const svn_string_t **value,
- apr_pool_t *pool);
-
/* Thunked version of svn_wc_notify_func_t callback type */
void svn_swig_pl_notify_func(void * baton,
const char *path,
@@ -278,11 +271,6 @@ void svn_swig_pl_make_editor(svn_delta_e
SV *perl_editor,
apr_pool_t *pool);
-void svn_swig_pl_wrap_window_handler(svn_txdelta_window_handler_t *handler,
- void **h_baton,
- SV *callback,
- apr_pool_t *pool);
-
/* svn_stream_t helpers */
svn_error_t *svn_swig_pl_make_stream(svn_stream_t **stream, SV *obj);
SV *svn_swig_pl_from_stream(svn_stream_t *stream);
Modified: subversion/branches/ra-git/subversion/bindings/swig/perl/native/Core.pm
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/perl/native/Core.pm?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/perl/native/Core.pm (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/perl/native/Core.pm Mon Nov 30 10:24:16 2015
@@ -959,6 +959,8 @@ use SVN::Base qw(Core svn_log_entry_t_);
=head2 svn_log_entry_t
+=over 4
+
=item $entry-E<gt>revision()
The revision of the commit.
@@ -988,6 +990,8 @@ in the same sense of C<_p_svn_merge_rang
Whether C<$entry-E<gt>revision()> is a merged revision resulting
from a reverse merge.
+=back
+
=cut
package _p_svn_auth_cred_simple_t;
Modified: subversion/branches/ra-git/subversion/bindings/swig/perl/native/Delta.pm
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/perl/native/Delta.pm?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/perl/native/Delta.pm (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/perl/native/Delta.pm Mon Nov 30 10:24:16 2015
@@ -101,12 +101,11 @@ use SVN::Base qw(Delta svn_txdelta_ appl
# special case for backward compatibility. When called with an additional
# argument "md5", it's the old style and don't return the md5.
-# Note that since the returned m5 is to be populated upon the last window
-# sent to the handler, it's not currently working to magically change things
-# in Perl land.
sub apply {
if (@_ == 5 || (@_ == 4 && ref($_[-1]) ne 'SVN::Pool' && ref($_[-1]) ne '_p_apr_pool_t')) {
- splice(@_, 3, 1);
+ # we're called as
+ # apply($source, $target, $result_digest, $error_info [, $pool])
+ splice(@_, 2, 1);
my @ret = SVN::_Delta::svn_txdelta_apply(@_);
return @ret[1,2];
}
Modified: subversion/branches/ra-git/subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c Mon Nov 30 10:24:16 2015
@@ -464,7 +464,7 @@ static PyObject *make_ob_error(svn_error
if (err)
return svn_swig_NewPointerObjString(err, "svn_error_t *", NULL);
else
- return Py_None;
+ Py_RETURN_NONE;
}
@@ -1529,8 +1529,9 @@ finished:
static svn_error_t *callback_bad_return_error(const char *message)
{
PyErr_SetString(PyExc_TypeError, message);
- return svn_error_create(APR_EGENERAL, NULL,
- "Python callback returned an invalid object");
+ return svn_error_createf(APR_EGENERAL, NULL,
+ "Python callback returned an invalid object: %s",
+ message);
}
/* Return a generic error about not being able to map types. */
Modified: subversion/branches/ra-git/subversion/bindings/swig/python/svn/core.py
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/python/svn/core.py?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/python/svn/core.py (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/python/svn/core.py Mon Nov 30 10:24:16 2015
@@ -32,14 +32,6 @@ import sys
class SubversionException(Exception):
- # Python 2.6 deprecated BaseException.message, which we inadvertently use.
- # We override it here, so the users of this class are spared from
- # DeprecationWarnings.
- # Note that BaseException.message is not deprecated in Python 2.5, and
- # isn't present in all other versions.
- if sys.version_info[0:2] == (2, 6):
- message = None
-
def __init__(self, message=None, apr_err=None, child=None,
file=None, line=None):
"""Initialize a new Subversion exception object.
Modified: subversion/branches/ra-git/subversion/bindings/swig/python/tests/run_all.py
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/python/tests/run_all.py?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/python/tests/run_all.py (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/python/tests/run_all.py Mon Nov 30 10:24:16 2015
@@ -21,11 +21,15 @@
import unittest, setup_path
import mergeinfo, core, client, delta, checksum, pool, ra, wc, repository, \
auth, trac.versioncontrol.tests
+from svn.core import svn_cache_config_get, svn_cache_config_set
# Run all tests
def suite():
"""Run all tests"""
+ settings = svn_cache_config_get()
+ settings.cache_size = long(1024*1024*32) ### Need explicit long
+ svn_cache_config_set(settings)
s = unittest.TestSuite()
s.addTest(core.suite())
s.addTest(checksum.suite())
Modified: subversion/branches/ra-git/subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb__pre_ruby.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb__pre_ruby.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb__pre_ruby.h (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb__pre_ruby.h Mon Nov 30 10:24:16 2015
@@ -85,6 +85,11 @@ typedef unsigned __int64 uint64_t;
#undef HAVE_INTTYPES_H
#endif
+/* Visual Studio >= 2015 has timespec defined */
+#if _MSC_VER >= 1900
+#define HAVE_STRUCT_TIMESPEC
+#endif
+
#ifdef _MSC_VER
#pragma warning(disable: 4702) /* warning C4702: unreachable code */
#endif
Modified: subversion/branches/ra-git/subversion/bindings/swig/ruby/test/my-assertions.rb
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/ruby/test/my-assertions.rb?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/ruby/test/my-assertions.rb (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/ruby/test/my-assertions.rb Mon Nov 30 10:24:16 2015
@@ -27,9 +27,7 @@ module Test
# make an intermediary assertion block handler
def _my_assert_block(&block)
if RUBY_VERSION > '1.9'
- assert_block do
- yield
- end
+ yield
else
_wrap_assertion do
yield
Modified: subversion/branches/ra-git/subversion/bindings/swig/ruby/test/test_wc.rb
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/ruby/test/test_wc.rb?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/ruby/test/test_wc.rb (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/ruby/test/test_wc.rb Mon Nov 30 10:24:16 2015
@@ -1068,15 +1068,10 @@ EOE
def test_context_create
assert_nothing_raised do
- result = Svn::Wc::Context.create do |context|
+ Svn::Wc::Context.create do |context|
assert_not_nil context
assert_kind_of Svn::Wc::Context, context
end
- if RUBY_VERSION > '1.9'
- assert_equal(result,true)
- else
- assert_nil result
- end
end
end
Modified: subversion/branches/ra-git/subversion/bindings/swig/svn_client.i
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/bindings/swig/svn_client.i?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/bindings/swig/svn_client.i (original)
+++ subversion/branches/ra-git/subversion/bindings/swig/svn_client.i Mon Nov 30 10:24:16 2015
@@ -293,8 +293,9 @@ Callback: svn_client_diff_summarize_func
*/
#ifdef SWIGPERL
%typemap(in) apr_hash_t *config {
- $1 = svn_swig_pl_objs_to_hash_by_name ($input, "svn_config_t *",
- svn_swig_pl_make_pool ((SV *)NULL));
+ apr_pool_t *pool = svn_swig_pl_make_pool ((SV *)NULL);
+ SPAGAIN;
+ $1 = svn_swig_pl_objs_to_hash_by_name ($input, "svn_config_t *", pool);
}
%typemap(out) apr_hash_t *config {
@@ -441,13 +442,13 @@ Callback: svn_client_diff_summarize_func
self = apr_palloc(pool, sizeof(*self));
self->path = path ? apr_pstrdup(pool, path) : NULL;
- revision = apr_palloc(pool, sizeof(revision));
+ revision = apr_palloc(pool, sizeof(*revision));
revision->kind = rev->kind;
revision->value.number = rev->value.number;
revision->value.date = rev->value.date;
self->revision = revision;
- peg_revision = apr_palloc(pool, sizeof(peg_revision));
+ peg_revision = apr_palloc(pool, sizeof(*peg_revision));
peg_revision->kind = peg_rev->kind;
peg_revision->value.number = peg_rev->value.number;
peg_revision->value.date = peg_rev->value.date;
Modified: subversion/branches/ra-git/subversion/include/private/svn_atomic.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_atomic.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_atomic.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_atomic.h Mon Nov 30 10:24:16 2015
@@ -76,21 +76,81 @@ extern "C" {
/** @} */
/**
+ * @name Single-threaded atomic initialization
+ * @{
+ */
+
+/**
+ * Callback for svn_atomic__init_once().
+ * @return an #svn_error_t if the initialization fails.
+ * @since New in 1.10
+ */
+typedef svn_error_t *(*svn_atomic__err_init_func_t)(void *baton,
+ apr_pool_t *pool);
+
+/**
+ * Callback for svn_atomic__init_no_error().
+ * @return a string containing an error message if the initialization fails.
+ * @since New in 1.10
+ */
+typedef const char *(*svn_atomic__str_init_func_t)(void *baton);
+
+/**
* Call an initialization function in a thread-safe manner.
*
* @a global_status must be a pointer to a global, zero-initialized
- * #svn_atomic_t. @a init_func is a pointer to the function that performs
- * the actual initialization. @a baton and and @a pool are passed on to the
- * init_func for its use.
+ * #svn_atomic_t. @a err_init_func is a pointer to the function that
+ * performs the actual initialization. @a baton and and @a pool are
+ * passed on to @a err_init_func for its use.
+ *
+ * @return the error returned by @a err_init_func.
*
* @since New in 1.5.
*/
svn_error_t *
svn_atomic__init_once(volatile svn_atomic_t *global_status,
- svn_error_t *(*init_func)(void*,apr_pool_t*),
+ svn_atomic__err_init_func_t err_init_func,
void *baton,
apr_pool_t* pool);
+/**
+ * Call an initialization function in a thread-safe manner.
+ *
+ * Unlike svn_atomic__init_once(), this function does not need a pool
+ * and does not create an #svn_error_t, and neither should the
+ * @a str_init_func implementation.
+ *
+ * @a global_status must be a pointer to a global, zero-initialized
+ * #svn_atomic_t. @a str_init_func is a pointer to the function that
+ * performs the actual initialization. @a baton is passed on to
+ * @a str_init_func for its use.
+ *
+ * @return the error string returned by @a str_init_func.
+ *
+ * @since New in 1.10.
+ */
+const char *
+svn_atomic__init_once_no_error(volatile svn_atomic_t *global_status,
+ svn_atomic__str_init_func_t str_init_func,
+ void *baton);
+
+
+/**
+ * Query and increment the global counter and set @a value to the new
+ * counter value.
+ *
+ * This function is thread-safe and you should call it whenever you need
+ * a number that is unique within the current process. The values are > 0.
+ *
+ * @return the error object in case of a synchronization failure.
+ *
+ * @since New in 1.10.
+ */
+svn_error_t *
+svn_atomic__unique_counter(apr_uint64_t* value);
+
+/** @} */
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
Modified: subversion/branches/ra-git/subversion/include/private/svn_auth_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_auth_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_auth_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_auth_private.h Mon Nov 30 10:24:16 2015
@@ -234,10 +234,12 @@ svn_auth__ssl_client_cert_pw_set(svn_boo
/* Apply the specified configuration for connecting with SERVER_NAME
to the auth baton */
svn_error_t *
-svn_auth__apply_config_for_server(svn_auth_baton_t *ab,
- apr_hash_t *config,
- const char *server_name,
- apr_pool_t *scratch_pool);
+svn_auth__make_session_auth(svn_auth_baton_t **session_auth_baton,
+ const svn_auth_baton_t *auth_baton,
+ apr_hash_t *config,
+ const char *server_name,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
#if (defined(WIN32) && !defined(__MINGW32__)) || defined(DOXYGEN)
/**
Modified: subversion/branches/ra-git/subversion/include/private/svn_cache.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_cache.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_cache.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_cache.h Mon Nov 30 10:24:16 2015
@@ -356,7 +356,12 @@ svn_cache__membuffer_cache_create(svn_me
*
* If @a thread_safe is true, and APR is compiled with threads, all
* accesses to the cache will be protected with a mutex, if the shared
- * @a memcache has also been created with thread_safe flag set.
+ * @a membuffer has also been created with thread_safe flag set.
+ *
+ * If @a short_lived is set, assume that the data stored through this
+ * cache will probably only be needed for a short period of time.
+ * Typically, some UUID is used as part of the prefix in that scenario.
+ * This flag is a mere hint and does not affect functionality.
*
* These caches do not support svn_cache__iter.
*/
@@ -369,10 +374,24 @@ svn_cache__create_membuffer_cache(svn_ca
const char *prefix,
apr_uint32_t priority,
svn_boolean_t thread_safe,
+ svn_boolean_t short_lived,
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
/**
+ * Creates a null-cache instance in @a *cache_p, allocated from
+ * @a result_pool. The given @c id is the only data stored in it and can
+ * be retrieved through svn_cache__get_info().
+ *
+ * The cache object will immediately evict (reject) any data being added
+ * to it and will always report as empty.
+ */
+svn_error_t *
+svn_cache__create_null(svn_cache__t **cache_p,
+ const char *id,
+ apr_pool_t *result_pool);
+
+/**
* Sets @a handler to be @a cache's error handling routine. If any
* error is returned from a call to svn_cache__get or svn_cache__set, @a
* handler will be called with @a baton and the error, and the
Modified: subversion/branches/ra-git/subversion/include/private/svn_client_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_client_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_client_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_client_private.h Mon Nov 30 10:24:16 2015
@@ -40,6 +40,51 @@ extern "C" {
#endif /* __cplusplus */
+/* Set *REVNUM to the revision number identified by REVISION.
+
+ If REVISION->kind is svn_opt_revision_number, just use
+ REVISION->value.number, ignoring LOCAL_ABSPATH and RA_SESSION.
+
+ Else if REVISION->kind is svn_opt_revision_committed,
+ svn_opt_revision_previous, or svn_opt_revision_base, or
+ svn_opt_revision_working, then the revision can be identified
+ purely based on the working copy's administrative information for
+ LOCAL_ABSPATH, so RA_SESSION is ignored. If LOCAL_ABSPATH is not
+ under revision control, return SVN_ERR_UNVERSIONED_RESOURCE, or if
+ LOCAL_ABSPATH is null, return SVN_ERR_CLIENT_VERSIONED_PATH_REQUIRED.
+
+ Else if REVISION->kind is svn_opt_revision_date or
+ svn_opt_revision_head, then RA_SESSION is used to retrieve the
+ revision from the repository (using REVISION->value.date in the
+ former case), and LOCAL_ABSPATH is ignored. If RA_SESSION is null,
+ return SVN_ERR_CLIENT_RA_ACCESS_REQUIRED.
+
+ Else if REVISION->kind is svn_opt_revision_unspecified, set
+ *REVNUM to SVN_INVALID_REVNUM.
+
+ If YOUNGEST_REV is non-NULL, it is an in/out parameter. If
+ *YOUNGEST_REV is valid, use it as the youngest revision in the
+ repository (regardless of reality) -- don't bother to lookup the
+ true value for HEAD, and don't return any value in *REVNUM greater
+ than *YOUNGEST_REV. If *YOUNGEST_REV is not valid, and a HEAD
+ lookup is required to populate *REVNUM, then also populate
+ *YOUNGEST_REV with the result. This is useful for making multiple
+ serialized calls to this function with a basically static view of
+ the repository, avoiding race conditions which could occur between
+ multiple invocations with HEAD lookup requests.
+
+ Else return SVN_ERR_CLIENT_BAD_REVISION.
+
+ Use SCRATCH_POOL for any temporary allocation. */
+svn_error_t *
+svn_client__get_revision_number(svn_revnum_t *revnum,
+ svn_revnum_t *youngest_rev,
+ svn_wc_context_t *wc_ctx,
+ const char *local_abspath,
+ svn_ra_session_t *ra_session,
+ const svn_opt_revision_t *revision,
+ apr_pool_t *scratch_pool);
+
/* Return true if KIND is a revision kind that is dependent on the working
* copy. Otherwise, return false. */
#define SVN_CLIENT__REVKIND_NEEDS_WC(kind) \
Modified: subversion/branches/ra-git/subversion/include/private/svn_cmdline_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_cmdline_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_cmdline_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_cmdline_private.h Mon Nov 30 10:24:16 2015
@@ -88,11 +88,15 @@ typedef struct svn_cmdline__config_argum
* containing svn_cmdline__config_argument_t* elements, allocating the option
* data in @a pool
*
+ * [Since 1.9:] If the file, section, or option value is not recognized,
+ * warn to @c stderr, using @a prefix as in svn_handle_warning2().
+ *
* @since New in 1.7.
*/
svn_error_t *
svn_cmdline__parse_config_option(apr_array_header_t *config_options,
const char *opt_arg,
+ const char *prefix,
apr_pool_t *pool);
/** Sets the config options in @a config_options, an apr array containing
@@ -209,6 +213,18 @@ svn_cmdline__getopt_init(apr_getopt_t **
const char *argv[],
apr_pool_t *pool);
+/* */
+svn_boolean_t
+svn_cmdline__stdin_is_a_terminal(void);
+
+/* */
+svn_boolean_t
+svn_cmdline__stdout_is_a_terminal(void);
+
+/* */
+svn_boolean_t
+svn_cmdline__stderr_is_a_terminal(void);
+
/* Determine whether interactive mode should be enabled, based on whether
* the user passed the --non-interactive or --force-interactive options.
* If neither option was passed, interactivity is enabled if standard
@@ -220,6 +236,20 @@ svn_boolean_t
svn_cmdline__be_interactive(svn_boolean_t non_interactive,
svn_boolean_t force_interactive);
+/* Parses the argument value of '--trust-server-cert-failures' OPT_ARG into
+ * the expected booleans for passing to svn_cmdline_create_auth_baton2()
+ *
+ * @since New in 1.9.
+ */
+svn_error_t *
+svn_cmdline__parse_trust_options(
+ svn_boolean_t *trust_server_cert_unknown_ca,
+ svn_boolean_t *trust_server_cert_cn_mismatch,
+ svn_boolean_t *trust_server_cert_expired,
+ svn_boolean_t *trust_server_cert_not_yet_valid,
+ svn_boolean_t *trust_server_cert_other_failure,
+ const char *opt_arg,
+ apr_pool_t *scratch_pool);
#ifdef __cplusplus
}
Modified: subversion/branches/ra-git/subversion/include/private/svn_delta_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_delta_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_delta_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_delta_private.h Mon Nov 30 10:24:16 2015
@@ -108,6 +108,25 @@ svn_txdelta__read_raw_window_len(apr_siz
svn_stream_t *stream,
apr_pool_t *pool);
+/* Return a debug editor that wraps @a wrapped_editor.
+ *
+ * The debug editor simply prints an indication of what callbacks are being
+ * called to @c stdout, and is only intended for use in debugging subversion
+ * editors.
+ *
+ * @a prefix, if non-null, is printed between "DBG: " and each indication.
+ *
+ * Note: Our test suite generally ignores stdout lines starting with "DBG:".
+ */
+svn_error_t *
+svn_delta__get_debug_editor(const svn_delta_editor_t **editor,
+ void **edit_baton,
+ const svn_delta_editor_t *wrapped_editor,
+ void *wrapped_baton,
+ const char *prefix,
+ apr_pool_t *pool);
+
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
Modified: subversion/branches/ra-git/subversion/include/private/svn_dep_compat.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_dep_compat.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_dep_compat.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_dep_compat.h Mon Nov 30 10:24:16 2015
@@ -75,6 +75,27 @@ extern "C" {
#endif
/**
+ * Indicate whether we are running on a POSIX platform. This has
+ * implications on the way e.g. fsync() works.
+ *
+ * For details on this check, see
+ * http://nadeausoftware.com/articles/2012/01/c_c_tip_how_use_compiler_predefined_macros_detect_operating_system#POSIX
+ *
+ * @since New in 1.10.
+ */
+#ifndef SVN_ON_POSIX
+#if !defined(_WIN32) \
+ && ( defined(__unix__) \
+ || defined(__unix) \
+ || (defined(__APPLE__) && defined(__MACH__))) /* UNIX-style OS? */
+# include <unistd.h>
+# if defined(_POSIX_VERSION)
+# define SVN_ON_POSIX
+# endif
+#endif
+#endif
+
+/**
* APR keeps a few interesting defines hidden away in its private
* headers apr_arch_file_io.h, so we redefined them here.
*
Modified: subversion/branches/ra-git/subversion/include/private/svn_diff_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_diff_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_diff_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_diff_private.h Mon Nov 30 10:24:16 2015
@@ -113,6 +113,33 @@ svn_diff__display_prop_diffs(svn_stream_
void *cancel_baton,
apr_pool_t *scratch_pool);
+/** Create a hunk object that adds a single line without newline. Return the
+ * new object in @a *hunk.
+ *
+ * @a line is the added text, without a trailing newline.
+ *
+ * The hunk will be associated with @a patch.
+ */
+svn_error_t *
+svn_diff_hunk__create_adds_single_line(svn_diff_hunk_t **hunk,
+ const char *line,
+ const svn_patch_t *patch,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
+
+/** Create a hunk object that deletes a single line without newline. Return
+ * the new object in @a *hunk.
+ *
+ * @a line is the deleted text, without a trailing newline.
+ *
+ * The hunk will be associated with @a patch.
+ */
+svn_error_t *
+svn_diff_hunk__create_deletes_single_line(svn_diff_hunk_t **hunk,
+ const char *line,
+ const svn_patch_t *patch,
+ apr_pool_t *result_pool,
+ apr_pool_t *scratch_pool);
#ifdef __cplusplus
}
Modified: subversion/branches/ra-git/subversion/include/private/svn_diff_tree.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_diff_tree.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_diff_tree.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_diff_tree.h Mon Nov 30 10:24:16 2015
@@ -114,12 +114,24 @@ extern "C" {
* ### How come many users don't set the 'repos_relpath' field? */
typedef struct svn_diff_source_t
{
- /* Always available */
+ /* Always available
+ In case of copyfrom: the revision copied from
+ */
svn_revnum_t revision;
- /* Depending on the driver available for copyfrom */
- /* ### What? */
+ /* In case of copyfrom: the repository relative path copied from.
+
+ NULL if the node wasn't copied or moved, or when the driver doesn't
+ have this information */
const char *repos_relpath;
+
+ /* In case of copyfrom: the relative path of source location before the
+ move. This path is relative WITHIN THE DIFF. The repository path is
+ typically in repos_relpath
+
+ NULL if the node wasn't moved or if the driver doesn't have this
+ information. */
+ const char *moved_from_relpath;
} svn_diff_source_t;
/**
Modified: subversion/branches/ra-git/subversion/include/private/svn_fs_fs_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_fs_fs_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_fs_fs_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_fs_fs_private.h Mon Nov 30 10:24:16 2015
@@ -53,7 +53,8 @@ typedef struct svn_fs_fs__large_change_i
/* size of the (deltified) representation */
apr_uint64_t size;
- /* Revision of the representation. SVN_INVALID_REVNUM for unused entries. */
+ /* Revision of the representation. SVN_INVALID_REVNUM for unused entries.
+ */
svn_revnum_t revision;
/* node path. "" for unused instances */
@@ -151,6 +152,9 @@ typedef struct svn_fs_fs__representation
/* sum of ref_count * expanded_size,
* i.e. total plaintext content if there was no rep sharing */
apr_uint64_t expanded_size;
+
+ /* sum of all representation delta chain lengths */
+ apr_uint64_t chain_len;
} svn_fs_fs__representation_stats_t;
/* Basic statistics we collect over a given set of noderevs.
@@ -267,19 +271,20 @@ svn_fs_fs__get_stats(svn_fs_fs__stats_t
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
-/* Node-revision IDs in FSFS consist of 3 of sub-IDs ("parts") that consist
+/* A node-revision ID in FSFS consists of 3 sub-IDs ("parts") that consist
* of a creation REVISION number and some revision- / transaction-local
* counter value (NUMBER). Old-style ID parts use global counter values.
*
* The parts are: node_id, copy_id and txn_id for in-txn IDs as well as
- * node_id, copy_id and rev_offset for in-revision IDs. This struct the
+ * node_id, copy_id and rev_item for in-revision IDs. This struct is the
* data structure used for each of those parts.
*/
typedef struct svn_fs_fs__id_part_t
{
- /* SVN_INVALID_REVNUM for txns -> not a txn, COUNTER must be 0.
- SVN_INVALID_REVNUM for others -> not assigned to a revision, yet.
- 0 for others -> old-style ID or the root in rev 0. */
+ /* SVN_INVALID_REVNUM for txn_id part -> not a txn, NUMBER must be 0.
+ SVN_INVALID_REVNUM for other parts -> not assigned to a revision, yet.
+ 0 for other parts -> old-style ID or the root in rev 0.
+ */
svn_revnum_t revision;
/* sub-id value relative to REVISION. Its interpretation depends on
Modified: subversion/branches/ra-git/subversion/include/private/svn_io_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_io_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_io_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_io_private.h Mon Nov 30 10:24:16 2015
@@ -171,6 +171,26 @@ svn_error_t*
svn_io__utf8_to_unicode_longpath(const WCHAR **result,
const char *source,
apr_pool_t *result_pool);
+
+/* This Windows-specific function marks the file to be deleted on close using
+ an existing file handle. It can be used to avoid having to reopen the file
+ as part of the delete handling. Return SVN_ERR_UNSUPPORTED_FEATURE if
+ delete on close operation is not supported by OS. */
+svn_error_t *
+svn_io__win_delete_file_on_close(apr_file_t *file,
+ const char *path,
+ apr_pool_t *pool);
+
+/* This Windows-specific function renames the file using an existing file
+ handle. It can be used to avoid having to reopen the file as part of the
+ rename operation. Return SVN_ERR_UNSUPPORTED_FEATURE if renaming open
+ file is not supported by OS.*/
+svn_error_t *
+svn_io__win_rename_open_file(apr_file_t *file,
+ const char *from_path,
+ const char *to_path,
+ apr_pool_t *pool);
+
#endif /* WIN32 */
#ifdef __cplusplus
Modified: subversion/branches/ra-git/subversion/include/private/svn_mutex.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_mutex.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_mutex.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_mutex.h Mon Nov 30 10:24:16 2015
@@ -27,8 +27,6 @@
#ifndef SVN_MUTEX_H
#define SVN_MUTEX_H
-#include <apr_thread_mutex.h>
-
#include "svn_error.h"
#ifdef __cplusplus
@@ -106,6 +104,17 @@ do {
SVN_ERR(svn_mutex__unlock(svn_mutex__m, (expr))); \
} while (0)
+#if APR_HAS_THREADS
+
+/** Return the APR mutex encapsulated in @a mutex.
+ *
+ * @note This function should only be called by APR wrapper code.
+ */
+apr_thread_mutex_t *
+svn_mutex__get(svn_mutex__t *mutex);
+
+#endif
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
Modified: subversion/branches/ra-git/subversion/include/private/svn_ra_svn_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_ra_svn_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_ra_svn_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_ra_svn_private.h Mon Nov 30 10:24:16 2015
@@ -34,6 +34,99 @@
extern "C" {
#endif /* __cplusplus */
+/** Memory representation of an on-the-wire data item. */
+typedef struct svn_ra_svn__item_t svn_ra_svn__item_t;
+
+/* A list of svn_ra_svn__item_t objects. */
+typedef struct svn_ra_svn__list_t
+{
+ /* List contents (array). May be NULL if NELTS is 0. */
+ struct svn_ra_svn__item_t *items;
+
+ /* Number of elements in ITEMS. */
+ int nelts;
+} svn_ra_svn__list_t;
+
+/* List element access macro. */
+#define SVN_RA_SVN__LIST_ITEM(list, idx) (list)->items[idx]
+
+/** Memory representation of an on-the-wire data item. */
+struct svn_ra_svn__item_t
+{
+ /** Variant indicator. */
+ svn_ra_svn_item_kind_t kind;
+
+ /** Variant data. */
+ union {
+ apr_uint64_t number;
+ svn_string_t string;
+ svn_string_t word;
+ svn_ra_svn__list_t list;
+ } u;
+};
+
+/** Command handler, used by svn_ra_svn__handle_commands(). */
+typedef svn_error_t *(*svn_ra_svn__command_handler)(svn_ra_svn_conn_t *conn,
+ apr_pool_t *pool,
+ svn_ra_svn__list_t *params,
+ void *baton);
+
+/** Command table, used by svn_ra_svn_handle_commands().
+ */
+typedef struct svn_ra_svn__cmd_entry_t
+{
+ /** Name of the command */
+ const char *cmdname;
+
+ /** Handler for the command */
+ svn_ra_svn__command_handler handler;
+
+ /** Only set when used through a deprecated API.
+ * HANDLER is NULL in that case. */
+ svn_ra_svn_command_handler deprecated_handler;
+
+ /** Termination flag. If set, command-handling will cease after
+ * command is processed. */
+ svn_boolean_t terminate;
+} svn_ra_svn__cmd_entry_t;
+
+
+/* Return a deep copy of the SOURCE array containing private API
+ * svn_ra_svn__item_t SOURCE to public API *TARGET, allocating
+ * sub-structures in RESULT_POOL. */
+apr_array_header_t *
+svn_ra_svn__to_public_array(const svn_ra_svn__list_t *source,
+ apr_pool_t *result_pool);
+
+/* Deep copy contents from private API *SOURCE to public API *TARGET,
+ * allocating sub-structures in RESULT_POOL. */
+void
+svn_ra_svn__to_public_item(svn_ra_svn_item_t *target,
+ const svn_ra_svn__item_t *source,
+ apr_pool_t *result_pool);
+
+svn_ra_svn__list_t *
+svn_ra_svn__to_private_array(const apr_array_header_t *source,
+ apr_pool_t *result_pool);
+
+/* Deep copy contents from public API *SOURCE to private API *TARGET,
+ * allocating sub-structures in RESULT_POOL. */
+void
+svn_ra_svn__to_private_item(svn_ra_svn__item_t *target,
+ const svn_ra_svn_item_t *source,
+ apr_pool_t *result_pool);
+
+/** Add the capabilities in @a list to @a conn's capabilities.
+ * @a list contains svn_ra_svn__item_t entries (which should be of type
+ * SVN_RA_SVN_WORD; a malformed data error will result if any are not).
+ *
+ * This is idempotent: if a given capability was already set for
+ * @a conn, it remains set.
+ */
+svn_error_t *
+svn_ra_svn__set_capabilities(svn_ra_svn_conn_t *conn,
+ const svn_ra_svn__list_t *list);
+
/**
* Set the shim callbacks to be used by @a conn to @a shim_callbacks.
@@ -175,7 +268,7 @@ svn_ra_svn__write_tuple(svn_ra_svn_conn_
svn_error_t *
svn_ra_svn__read_item(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- svn_ra_svn_item_t **item);
+ svn_ra_svn__item_t **item);
/** Scan data on @a conn until we find something which looks like the
* beginning of an svn server greeting (an open paren followed by a
@@ -226,8 +319,7 @@ svn_ra_svn__skip_leading_garbage(svn_ra_
* 'b' may not appear inside an optional tuple specification; use '3' instead.
*/
svn_error_t *
-svn_ra_svn__parse_tuple(const apr_array_header_t *list,
- apr_pool_t *pool,
+svn_ra_svn__parse_tuple(const svn_ra_svn__list_t *list,
const char *fmt, ...);
/** Read a tuple from the network and parse it as a tuple, using the
@@ -238,13 +330,13 @@ svn_ra_svn__read_tuple(svn_ra_svn_conn_t
apr_pool_t *pool,
const char *fmt, ...);
-/** Parse an array of @c svn_ra_svn_item_t structures as a list of
+/** Parse an array of @c svn_ra_svn__item_t structures as a list of
* properties, storing the properties in a hash table.
*
* @since New in 1.5.
*/
svn_error_t *
-svn_ra_svn__parse_proplist(const apr_array_header_t *list,
+svn_ra_svn__parse_proplist(const svn_ra_svn__list_t *list,
apr_pool_t *pool,
apr_hash_t **props);
@@ -300,7 +392,7 @@ svn_ra_svn__handle_command(svn_boolean_t
svn_error_t *
svn_ra_svn__handle_commands2(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const svn_ra_svn_cmd_entry_t *commands,
+ const svn_ra_svn__cmd_entry_t *commands,
void *baton,
svn_boolean_t error_on_disconnect);
@@ -347,7 +439,7 @@ svn_error_t *
svn_ra_svn__write_cmd_open_root(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
svn_revnum_t rev,
- const char *token);
+ const svn_string_t *token);
/** Send a "delete-entry" command over connection @a conn. Delete the
* @a path at optional revision @a rev below @a parent_token.
@@ -358,7 +450,7 @@ svn_ra_svn__write_cmd_delete_entry(svn_r
apr_pool_t *pool,
const char *path,
svn_revnum_t rev,
- const char *parent_token);
+ const svn_string_t *parent_token);
/** Send a "add-dir" command over connection @a conn. Add a new directory
* node named @a path under the directory identified by @a parent_token.
@@ -370,8 +462,8 @@ svn_error_t *
svn_ra_svn__write_cmd_add_dir(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token,
- const char *token,
+ const svn_string_t *parent_token,
+ const svn_string_t *token,
const char *copy_path,
svn_revnum_t copy_rev);
@@ -384,8 +476,8 @@ svn_error_t *
svn_ra_svn__write_cmd_open_dir(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token,
- const char *token,
+ const svn_string_t *parent_token,
+ const svn_string_t *token,
svn_revnum_t rev);
/** Send a "change-dir-prop" command over connection @a conn. Set the
@@ -395,7 +487,7 @@ svn_ra_svn__write_cmd_open_dir(svn_ra_sv
svn_error_t *
svn_ra_svn__write_cmd_change_dir_prop(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token,
+ const svn_string_t *token,
const char *name,
const svn_string_t *value);
@@ -406,7 +498,7 @@ svn_ra_svn__write_cmd_change_dir_prop(sv
svn_error_t *
svn_ra_svn__write_cmd_close_dir(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token);
+ const svn_string_t *token);
/** Send a "absent-dir" command over connection @a conn. Directory node
* named @a path under the directory identified by @a parent_token is
@@ -416,7 +508,7 @@ svn_error_t *
svn_ra_svn__write_cmd_absent_dir(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token);
+ const svn_string_t *parent_token);
/** Send a "add-file" command over connection @a conn. Add a new file
* node named @a path under the directory identified by @a parent_token.
@@ -428,8 +520,8 @@ svn_error_t *
svn_ra_svn__write_cmd_add_file(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token,
- const char *token,
+ const svn_string_t *parent_token,
+ const svn_string_t *token,
const char *copy_path,
svn_revnum_t copy_rev);
@@ -442,8 +534,8 @@ svn_error_t *
svn_ra_svn__write_cmd_open_file(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token,
- const char *token,
+ const svn_string_t *parent_token,
+ const svn_string_t *token,
svn_revnum_t rev);
/** Send a "change-file-prop" command over connection @a conn. Set the
@@ -453,7 +545,7 @@ svn_ra_svn__write_cmd_open_file(svn_ra_s
svn_error_t *
svn_ra_svn__write_cmd_change_file_prop(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token,
+ const svn_string_t *token,
const char *name,
const svn_string_t *value);
@@ -465,7 +557,7 @@ svn_ra_svn__write_cmd_change_file_prop(s
svn_error_t *
svn_ra_svn__write_cmd_close_file(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token,
+ const svn_string_t *token,
const char *text_checksum);
/** Send a "absent-file" command over connection @a conn. File node
@@ -476,7 +568,7 @@ svn_error_t *
svn_ra_svn__write_cmd_absent_file(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *parent_token);
+ const svn_string_t *parent_token);
/** Send a "apply-textdelta" command over connection @a conn. Starts a
* series of text deltas to be applied to the file identified by @a token.
@@ -486,7 +578,7 @@ svn_ra_svn__write_cmd_absent_file(svn_ra
svn_error_t *
svn_ra_svn__write_cmd_apply_textdelta(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token,
+ const svn_string_t *token,
const char *base_checksum);
/** Send a "textdelta-chunk" command over connection @a conn. Apply
@@ -496,7 +588,7 @@ svn_ra_svn__write_cmd_apply_textdelta(sv
svn_error_t *
svn_ra_svn__write_cmd_textdelta_chunk(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token,
+ const svn_string_t *token,
const svn_string_t *chunk);
/** Send a "textdelta-end" command over connection @a conn. Ends the
@@ -506,7 +598,7 @@ svn_ra_svn__write_cmd_textdelta_chunk(sv
svn_error_t *
svn_ra_svn__write_cmd_textdelta_end(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
- const char *token);
+ const svn_string_t *token);
/** Send a "close-edit" command over connection @a conn. Ends the editor
* drive (successfully). Use @a pool for allocations.
@@ -790,7 +882,7 @@ svn_error_t *
svn_ra_svn__write_cmd_unlock(svn_ra_svn_conn_t *conn,
apr_pool_t *pool,
const char *path,
- const char *token,
+ const svn_string_t *token,
svn_boolean_t break_lock);
/** Send a "get-lock" command over connection @a conn.
@@ -931,7 +1023,7 @@ svn_ra_svn__write_data_log_entry(svn_ra_
* @see svn_log_changed_path2_t for a description of the output parameters.
*/
svn_error_t *
-svn_ra_svn__read_data_log_changed_entry(const apr_array_header_t *items,
+svn_ra_svn__read_data_log_changed_entry(const svn_ra_svn__list_t *items,
svn_string_t **cpath,
const char **action,
const char **copy_path,
Modified: subversion/branches/ra-git/subversion/include/private/svn_sorts_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_sorts_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_sorts_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_sorts_private.h Mon Nov 30 10:24:16 2015
@@ -53,12 +53,12 @@ struct svn_sort__item_t {
/** Sort @a ht according to its keys, return an @c apr_array_header_t
* containing @c svn_sort__item_t structures holding those keys and values
* (i.e. for each @c svn_sort__item_t @a item in the returned array,
- * @a item->key and @a item->size are the hash key, and @a item->value points to
+ * @a item.key and @a item.size are the hash key, and @a item.value points to
* the hash value).
*
* Storage is shared with the original hash, not copied.
*
- * @a comparison_func should take two @c svn_sort__item_t's and return an
+ * @a comparison_func should take pointers to two items and return an
* integer greater than, equal to, or less than 0, according as the first item
* is greater than, equal to, or less than the second.
*
Modified: subversion/branches/ra-git/subversion/include/private/svn_string_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_string_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_string_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_string_private.h Mon Nov 30 10:24:16 2015
@@ -131,6 +131,14 @@ svn_membuf__nzero(svn_membuf_t *membuf,
svn_string_t *
svn_stringbuf__morph_into_string(svn_stringbuf_t *strbuf);
+/** Utility macro to define static svn_string_t objects. @a value must
+ * be a static string; the "" in the macro declaration tries to ensure this.
+ *
+ * Usage:
+ * static const svn_string_t my_string = SVN__STATIC_STRING("my text");
+ */
+#define SVN__STATIC_STRING(value) { value "", sizeof(value "") - 1 }
+
/** Like strtoul but with a fixed base of 10 and without overflow checks.
* This allows the compiler to generate massively faster (4x on 64bit LINUX)
* code. Overflow checks may be added on the caller side where you might
Modified: subversion/branches/ra-git/subversion/include/private/svn_subr_private.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_subr_private.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_subr_private.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_subr_private.h Mon Nov 30 10:24:16 2015
@@ -525,6 +525,16 @@ svn_version__at_least(svn_version_t *ver
unsigned char *
svn__encode_uint(unsigned char *p, apr_uint64_t val);
+/* Wrapper around svn__encode_uint using the LSB to store the sign:
+ *
+ * If VAL >= 0
+ * UINT_VAL = 2 * VAL
+ * else
+ * UINT_VAL = (- 2 * VAL) - 1
+ */
+unsigned char *
+svn__encode_int(unsigned char *p, apr_int64_t val);
+
/* Decode an unsigned 7b/8b-encoded integer into *VAL and return a pointer
to the byte after the integer. The bytes to be decoded live in the
range [P..END-1]. If these bytes do not contain a whole encoded
@@ -537,20 +547,29 @@ svn__decode_uint(apr_uint64_t *val,
const unsigned char *p,
const unsigned char *end);
-/* Get the data from IN, compress it according to the specified
- * COMPRESSION_METHOD and write the result to OUT.
+/* Wrapper around svn__decode_uint, reversing the transformation performed
+ * by svn__encode_int.
+ */
+const unsigned char *
+svn__decode_int(apr_int64_t *val,
+ const unsigned char *p,
+ const unsigned char *end);
+
+/* Compress the data from DATA with length LEN, it according to the
+ * specified COMPRESSION_METHOD and write the result to OUT.
* SVN__COMPRESSION_NONE is valid for COMPRESSION_METHOD.
*/
svn_error_t *
-svn__compress(svn_stringbuf_t *in,
+svn__compress(const void *data, apr_size_t len,
svn_stringbuf_t *out,
int compression_method);
-/* Get the compressed data from IN, decompress it and write the result to
- * OUT. Return an error if the decompressed size is larger than LIMIT.
+/* Decompress the compressed data from DATA with length LEN and write the
+ * result to OUT. Return an error if the decompressed size is larger than
+ * LIMIT.
*/
svn_error_t *
-svn__decompress(svn_stringbuf_t *in,
+svn__decompress(const void *data, apr_size_t len,
svn_stringbuf_t *out,
apr_size_t limit);
@@ -681,8 +700,26 @@ svn_boolean_t
svn_bit_array__get(svn_bit_array__t *array,
apr_size_t idx);
+/* Return the global pool used by the DSO loader, this may be NULL if
+ no DSOs have been loaded. */
+apr_pool_t *
+svn_dso__pool(void);
+
/** @} */
+
+/* Return the xml (expat) version we compiled against. */
+const char *svn_xml__compiled_version(void);
+
+/* Return the xml (expat) version we run against. */
+const char *svn_xml__runtime_version(void);
+
+/* Return the zlib version we compiled against. */
+const char *svn_zlib__compiled_version(void);
+
+/* Return the zlib version we run against. */
+const char *svn_zlib__runtime_version(void);
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
Modified: subversion/branches/ra-git/subversion/include/private/svn_temp_serializer.h
URL: http://svn.apache.org/viewvc/subversion/branches/ra-git/subversion/include/private/svn_temp_serializer.h?rev=1717223&r1=1717222&r2=1717223&view=diff
==============================================================================
--- subversion/branches/ra-git/subversion/include/private/svn_temp_serializer.h (original)
+++ subversion/branches/ra-git/subversion/include/private/svn_temp_serializer.h Mon Nov 30 10:24:16 2015
@@ -206,7 +206,7 @@ svn_temp_serializer__get(svn_temp_serial
* the pointer to resolve in @a ptr.
*/
void
-svn_temp_deserializer__resolve(void *buffer, void **ptr);
+svn_temp_deserializer__resolve(const void *buffer, void **ptr);
/**
* Similar to svn_temp_deserializer__resolve() but instead of modifying