[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: SWIG client bindings and auth_baton

From: Stephen White <swhite_at_decisionsoft.com>
Date: 2003-05-12 18:08:02 CEST

---- Original Message ----
> From Philipp von Weitershausen <philipp@weitershausen.de>
> Date: Monday, 12 May 2003, 15:15
> > Without this function I can't see any way to create an auth_baton_t with
> > which to populate the client_ctx, and without doing that things tend to
> > segfault. Or at least that's why I think they're segfaulting.
> The way to create an auth_baton now is to call util.svn_auth_open().
> Consider the following script:
> # create the auth baton
> auth_baton = util.svn_auth_open(providers, pool)

Hmm, that doesn't seem to appear in the python bindings.

>>> from svn import util
>>> util.svn_auth_open
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
AttributeError: 'module' object has no attribute 'svn_auth_open'

However, I added svn_auth.h to util.i (see below) and rebuilt the Python
bindings and then your script worked a treat.

[swhite@ob subversion-svn]$ svn diff subversion/bindings/swig/util.i
Index: subversion/bindings/swig/util.i
--- subversion/bindings/swig/util.i (revision 5888)
+++ subversion/bindings/swig/util.i (working copy)
@@ -232,6 +232,7 @@
 #define __attribute__(x)
 %include svn_io.h
+%include svn_auth.h
 #include <apr.h>


Stephen White                               +44-1865-203192
DecisionSoft Limited                        http://www.decisionsoft.com
XML Development and Services
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon May 12 18:09:23 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.