summaryrefslogtreecommitdiff
path: root/source4/param/param.i
diff options
context:
space:
mode:
Diffstat (limited to 'source4/param/param.i')
-rw-r--r--source4/param/param.i12
1 files changed, 12 insertions, 0 deletions
diff --git a/source4/param/param.i b/source4/param/param.i
index 353fa3ced6..fdc9de233f 100644
--- a/source4/param/param.i
+++ b/source4/param/param.i
@@ -290,3 +290,15 @@ typedef struct param_section {
%rename(default_config) global_loadparm;
struct loadparm_context *global_loadparm;
+
+%{
+
+struct loadparm_context *lp_from_py_object(PyObject *py_obj)
+{
+ struct loadparm_context *lp_ctx;
+ if (SWIG_ConvertPtr(py_obj, &lp_ctx, SWIGTYPE_p_loadparm_context, 0 | 0 ) < 0)
+ return NULL;
+ return lp_ctx;
+}
+
+%}