On branch swig-py3: avoid crash when status is NULL
* subversion/bindings/swig/python/libsvn_swig_py/swigutil_py.c
(svn_swig_py_client_status_func) Allow NULL for status.
@@ -3057,7 +3057,20 @@ void svn_swig_py_client_status_func(void *baton,
if it is occurred, and restore error indicator */
PyErr_Fetch(&exc_type, &exc, &exc_traceback);
- if ((result = PyObject_CallFunction(function,
+ if (status == NULL)
+ {
+ result = PyObject_CallFunction(function,
+#if IS_PY3
+ (char *)"yOO&",
+#else
+ (char *)"sOO&",
+#endif
+ path, Py_None,
+ make_ob_pool, scratch_pool);
+ }
+ else
+ {
+ result = PyObject_CallFunction(function,
#if IS_PY3
(char *)"yO&O&",
#else
@@ -3065,7 +3078,9 @@ void svn_swig_py_client_status_func(void *baton,
#endif
path,
make_ob_client_status, status,
- make_ob_pool, scratch_pool)) == NULL)
+ make_ob_pool, scratch_pool);
+ }
+ if (result == NULL)
{
err = callback_exception_error();
}
