From 982bc5f569c04a9fefa8be52915be8803a0c953a Mon Sep 17 00:00:00 2001 From: Tim Potter Date: Tue, 19 Jul 2005 10:01:32 +0000 Subject: r8596: Don't wrap non-existent functions. Bugzilla #2895. (This used to be commit 0a9395bb486c80799ea14f0ebe7a371da34628b5) --- source3/python/py_tdb.c | 45 --------------------------------------------- 1 file changed, 45 deletions(-) (limited to 'source3/python') diff --git a/source3/python/py_tdb.c b/source3/python/py_tdb.c index ccd1e6e1c6..f73aa0ba8b 100644 --- a/source3/python/py_tdb.c +++ b/source3/python/py_tdb.c @@ -376,49 +376,6 @@ static BOOL make_lock_list(PyObject *py_keys, TDB_DATA **keys, int *num_keys) return True; } -PyObject *py_tdb_hnd_lock(PyObject *self, PyObject *args) -{ - tdb_hnd_object *obj = (tdb_hnd_object *)self; - PyObject *py_keys; - TDB_DATA *keys; - int num_keys, result; - - if (!obj->tdb) { - PyErr_SetString(py_tdb_error, "tdb object has been closed"); - return NULL; - } - - if (!PyArg_ParseTuple(args, "O", &py_keys)) - return NULL; - - if (!make_lock_list(py_keys, &keys, &num_keys)) - return NULL; - - result = tdb_lockkeys(obj->tdb, num_keys, keys); - - free(keys); - - return PyInt_FromLong(result != -1); -} - -PyObject *py_tdb_hnd_unlock(PyObject *self, PyObject *args) -{ - tdb_hnd_object *obj = (tdb_hnd_object *)self; - - if (!obj->tdb) { - PyErr_SetString(py_tdb_error, "tdb object has been closed"); - return NULL; - } - - if (!PyArg_ParseTuple(args, "")) - return NULL; - - tdb_unlockkeys(obj->tdb); - - Py_INCREF(Py_None); - return Py_None; -} - /* * tdb traversal */ @@ -582,8 +539,6 @@ static PyMethodDef tdb_hnd_methods[] = { { "next_key", (PyCFunction)py_tdb_hnd_next_key, METH_VARARGS }, { "lock_all", (PyCFunction)py_tdb_hnd_lock_all, METH_VARARGS }, { "unlock_all", (PyCFunction)py_tdb_hnd_unlock_all, METH_VARARGS }, - { "lock", (PyCFunction)py_tdb_hnd_lock, METH_VARARGS }, - { "unlock", (PyCFunction)py_tdb_hnd_unlock, METH_VARARGS }, { "traverse", (PyCFunction)py_tdb_hnd_traverse, METH_VARARGS | METH_KEYWORDS }, { "chainlock", (PyCFunction)py_tdb_hnd_chainlock, METH_VARARGS | METH_KEYWORDS }, { "chainunlock", (PyCFunction)py_tdb_hnd_chainunlock, METH_VARARGS | METH_KEYWORDS }, -- cgit