summaryrefslogtreecommitdiff
path: root/source4/scripting
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2009-01-06 04:13:57 +0100
committerJelmer Vernooij <jelmer@samba.org>2009-01-06 04:13:57 +0100
commitd2c70d24e12293d9b4272eb310a6a4c4582b2d92 (patch)
tree5cc5f08da2608a20e2f961b7fecdd50e9752ec50 /source4/scripting
parent1f8b6238dd161d29ee92902ea006158e180fa87b (diff)
downloadsamba-d2c70d24e12293d9b4272eb310a6a4c4582b2d92.tar.gz
samba-d2c70d24e12293d9b4272eb310a6a4c4582b2d92.tar.bz2
samba-d2c70d24e12293d9b4272eb310a6a4c4582b2d92.zip
py: Properly increase the reference counter of Py_None.
Diffstat (limited to 'source4/scripting')
-rw-r--r--source4/scripting/python/pyglue.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source4/scripting/python/pyglue.c b/source4/scripting/python/pyglue.c
index 24ffd58caf..6939979f18 100644
--- a/source4/scripting/python/pyglue.c
+++ b/source4/scripting/python/pyglue.c
@@ -88,7 +88,7 @@ static PyObject *py_ldb_set_credentials(PyObject *self, PyObject *args)
ldb_set_opaque(ldb, "credentials", creds);
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_ldb_set_loadparm(PyObject *self, PyObject *args)
@@ -109,7 +109,7 @@ static PyObject *py_ldb_set_loadparm(PyObject *self, PyObject *args)
ldb_set_opaque(ldb, "loadparm", lp_ctx);
- return Py_None;
+ Py_RETURN_NONE;
}
@@ -131,7 +131,7 @@ static PyObject *py_ldb_set_session_info(PyObject *self, PyObject *args)
ldb_set_opaque(ldb, "sessionInfo", info);
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_samdb_set_domain_sid(PyLdbObject *self, PyObject *args)
@@ -153,7 +153,7 @@ static PyObject *py_samdb_set_domain_sid(PyLdbObject *self, PyObject *args)
PyErr_SetString(PyExc_RuntimeError, "set_domain_sid failed");
return NULL;
}
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_ldb_register_samba_handlers(PyObject *self, PyObject *args)
@@ -169,7 +169,7 @@ static PyObject *py_ldb_register_samba_handlers(PyObject *self, PyObject *args)
ret = ldb_register_samba_handlers(ldb);
PyErr_LDB_ERROR_IS_ERR_RAISE(ret, ldb);
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_dsdb_set_ntds_invocation_id(PyObject *self, PyObject *args)
@@ -189,7 +189,7 @@ static PyObject *py_dsdb_set_ntds_invocation_id(PyObject *self, PyObject *args)
PyErr_SetString(PyExc_RuntimeError, "set_ntds_invocation_id failed");
return NULL;
}
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_dsdb_set_global_schema(PyObject *self, PyObject *args)
@@ -205,7 +205,7 @@ static PyObject *py_dsdb_set_global_schema(PyObject *self, PyObject *args)
ret = dsdb_set_global_schema(ldb);
PyErr_LDB_ERROR_IS_ERR_RAISE(ret, ldb);
- return Py_None;
+ Py_RETURN_NONE;
}
static PyObject *py_dsdb_attach_schema_from_ldif_file(PyObject *self, PyObject *args)
@@ -223,7 +223,7 @@ static PyObject *py_dsdb_attach_schema_from_ldif_file(PyObject *self, PyObject *
result = dsdb_attach_schema_from_ldif_file(ldb, pf, df);
PyErr_WERROR_IS_ERR_RAISE(result);
- return Py_None;
+ Py_RETURN_NONE;
}
static PyMethodDef py_misc_methods[] = {