diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2010-05-31 20:44:12 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2010-05-31 20:45:14 +0200 |
commit | 41cdac9c3e5b2e9eea3067892a3e60b4bff67154 (patch) | |
tree | 23868f0dec433948a05a8c6bb10f22adab2db5f1 /source4 | |
parent | 38dfc480334926f07b7d1869225370693140e349 (diff) | |
download | samba-41cdac9c3e5b2e9eea3067892a3e60b4bff67154.tar.gz samba-41cdac9c3e5b2e9eea3067892a3e60b4bff67154.tar.bz2 samba-41cdac9c3e5b2e9eea3067892a3e60b4bff67154.zip |
pyldb: Remove duplicate copy of function.
Diffstat (limited to 'source4')
-rw-r--r-- | source4/lib/ldb/pyldb.c | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/source4/lib/ldb/pyldb.c b/source4/lib/ldb/pyldb.c index ce149ccd95..fd7584dc6c 100644 --- a/source4/lib/ldb/pyldb.c +++ b/source4/lib/ldb/pyldb.c @@ -81,34 +81,6 @@ static PyObject *PyObject_FromLdbValue(struct ldb_context *ldb_ctx, } /** - * Obtain a ldb DN from a Python object. - * - * @param mem_ctx Memory context - * @param object Python object - * @param ldb_ctx LDB context - * @return Whether or not the conversion succeeded - */ -bool PyObject_AsDn(TALLOC_CTX *mem_ctx, PyObject *object, - struct ldb_context *ldb_ctx, struct ldb_dn **dn) -{ - struct ldb_dn *odn; - - if (ldb_ctx != NULL && PyString_Check(object)) { - odn = ldb_dn_new(mem_ctx, ldb_ctx, PyString_AsString(object)); - *dn = odn; - return true; - } - - if (PyLdbDn_Check(object)) { - *dn = PyLdbDn_AsDn(object); - return true; - } - - PyErr_SetString(PyExc_TypeError, "Expected DN"); - return false; -} - -/** * Create a Python object from a ldb_result. * * @param result LDB result to convert |