upgrade to final version of pysqlite 2.2.0

This commit is contained in:
Anthony Baxter 2006-04-05 18:25:33 +00:00
parent c48c8db110
commit 8e7b490890
11 changed files with 30 additions and 38 deletions

View file

@ -55,28 +55,19 @@ int
microprotocols_add(PyTypeObject *type, PyObject *proto, PyObject *cast)
{
PyObject* key;
int rc;
if (proto == NULL) proto = (PyObject*)&SQLitePrepareProtocolType;
/*
Dprintf("microprotocols_add: cast %p for (%s, ?)",
cast, type->tp_name);
*/
key = Py_BuildValue("(OO)", (PyObject*)type, proto);
if (!key) {
return -1;
}
if (PyDict_SetItem(psyco_adapters, key, cast) != 0) {
Py_DECREF(key);
return -1;
}
rc = PyDict_SetItem(psyco_adapters, key, cast);
Py_DECREF(key);
return 0;
return rc;
}
/* microprotocols_adapt - adapt an object to the built-in protocol */