Apply changes from pysqlite3.
This commit is contained in:
parent
941a18dcac
commit
d354b48238
4 changed files with 24 additions and 16 deletions
|
|
@ -112,9 +112,8 @@ void pysqlite_cache_dealloc(pysqlite_Cache* self)
|
|||
Py_TYPE(self)->tp_free((PyObject*)self);
|
||||
}
|
||||
|
||||
PyObject* pysqlite_cache_get(pysqlite_Cache* self, PyObject* args)
|
||||
PyObject* pysqlite_cache_get(pysqlite_Cache* self, PyObject* key)
|
||||
{
|
||||
PyObject* key = args;
|
||||
pysqlite_Node* node;
|
||||
pysqlite_Node* ptr;
|
||||
PyObject* data;
|
||||
|
|
@ -184,6 +183,9 @@ PyObject* pysqlite_cache_get(pysqlite_Cache* self, PyObject* args)
|
|||
}
|
||||
}
|
||||
|
||||
/* We cannot replace this by PyObject_CallOneArg() since
|
||||
* PyObject_CallFunction() has a special case when using a
|
||||
* single tuple as argument. */
|
||||
data = PyObject_CallFunction(self->factory, "O", key);
|
||||
|
||||
if (!data) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue