Greg Stein <gstein@lyra.org> writes:
> > - /* ### for now, we're leaving CHANGED_PATHS outta this. */
> > + if (changed_paths)
> > + chpaths = svn_swig_py_convert_hash (changed_paths, tinfo);
> > + else
> > + chpaths = Py_None;
> >
> > /* ### python doesn't have 'const' on the method name and format */
> > if ((result = PyObject_CallFunction(receiver,
> > - (char *)"lsssO&",
> > - rev, author, date, msg,
> > + (char *)"OlsssO&",
> > + chpaths, rev, author, date, msg,
> > make_ob_pool, pool)) == NULL)
> > {
> > return convert_python_error(pool);
>
> You need to refcount chpaths properly. svn_swig_py_convert_hash() will
> pass a ref back to you, which means you must DECREF it when you're done. To
> simplify the decref logic, you can just incref Py_None before putting it
> into chpaths. After the function call, then you need to decref chpaths (and
> ensure that you do the decref in the error case, too)
Doh! You're absolutely right. Will fix this when next I'm in a State
of Hacking.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Sep 21 16:47:29 2002