svn commit: samba r8596 - branches/SAMBA_3_0/source/python
trunk/source/python
tpot at samba.org
tpot at samba.org
Tue Jul 19 10:01:32 GMT 2005
Author: tpot
Date: 2005-07-19 10:01:32 +0000 (Tue, 19 Jul 2005)
New Revision: 8596
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=8596
Log:
Don't wrap non-existent functions. Bugzilla #2895.
Modified:
branches/SAMBA_3_0/source/python/py_tdb.c
trunk/source/python/py_tdb.c
Changeset:
Modified: branches/SAMBA_3_0/source/python/py_tdb.c
===================================================================
--- branches/SAMBA_3_0/source/python/py_tdb.c 2005-07-19 09:59:37 UTC (rev 8595)
+++ branches/SAMBA_3_0/source/python/py_tdb.c 2005-07-19 10:01:32 UTC (rev 8596)
@@ -376,49 +376,6 @@
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 @@
{ "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 },
Modified: trunk/source/python/py_tdb.c
===================================================================
--- trunk/source/python/py_tdb.c 2005-07-19 09:59:37 UTC (rev 8595)
+++ trunk/source/python/py_tdb.c 2005-07-19 10:01:32 UTC (rev 8596)
@@ -376,49 +376,6 @@
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 @@
{ "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 },
More information about the samba-cvs
mailing list