diff options
author | Erlend Egeberg Aasland <erlend.aasland@innova.no> | 2021-10-27 11:12:21 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-27 11:12:21 (GMT) |
commit | 8f24b7dbcbd83311dad510863d8cb41f0e91b464 (patch) | |
tree | 036b2a0f04c7c1b9009ea4bb0d904cde920bd84c /Modules/_sqlite/microprotocols.c | |
parent | 82a662e5216a9b3969054c540a759a9493468510 (diff) | |
download | cpython-8f24b7dbcbd83311dad510863d8cb41f0e91b464.zip cpython-8f24b7dbcbd83311dad510863d8cb41f0e91b464.tar.gz cpython-8f24b7dbcbd83311dad510863d8cb41f0e91b464.tar.bz2 |
bpo-42064: Convert `sqlite3` global state to module state (GH-29073)
Diffstat (limited to 'Modules/_sqlite/microprotocols.c')
-rw-r--r-- | Modules/_sqlite/microprotocols.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/_sqlite/microprotocols.c b/Modules/_sqlite/microprotocols.c index 68e4f7f..95c799d 100644 --- a/Modules/_sqlite/microprotocols.c +++ b/Modules/_sqlite/microprotocols.c @@ -49,7 +49,8 @@ pysqlite_microprotocols_init(PyObject *module) /* pysqlite_microprotocols_add - add a reverse type-caster to the dictionary */ int -pysqlite_microprotocols_add(PyTypeObject *type, PyObject *proto, PyObject *cast) +pysqlite_microprotocols_add(pysqlite_state *state, PyTypeObject *type, + PyObject *proto, PyObject *cast) { PyObject* key; int rc; @@ -61,7 +62,6 @@ pysqlite_microprotocols_add(PyTypeObject *type, PyObject *proto, PyObject *cast) return -1; } - pysqlite_state *state = pysqlite_get_state(NULL); rc = PyDict_SetItem(state->psyco_adapters, key, cast); Py_DECREF(key); |