summaryrefslogtreecommitdiff
path: root/subversion/bindings/swig/include/svn_string.swg
diff options
context:
space:
mode:
Diffstat (limited to 'subversion/bindings/swig/include/svn_string.swg')
-rw-r--r--subversion/bindings/swig/include/svn_string.swg11
1 files changed, 4 insertions, 7 deletions
diff --git a/subversion/bindings/swig/include/svn_string.swg b/subversion/bindings/swig/include/svn_string.swg
index 2a04672..9fb2dac 100644
--- a/subversion/bindings/swig/include/svn_string.swg
+++ b/subversion/bindings/swig/include/svn_string.swg
@@ -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");
}
@@ -208,11 +210,6 @@ typedef struct svn_string_t svn_string_t;
/* when storing an svn_string_t* into a structure, we must allocate the
svn_string_t structure on the heap. */
-#ifdef SWIGPYTHON
-%typemap(memberin) const svn_string_t * {
- $1 = svn_string_dup($input, _global_pool);
-}
-#endif
#ifdef SWIGPERL
%typemap(memberin) const svn_string_t * {
$1 = svn_string_dup($input, _global_pool);