summaryrefslogtreecommitdiffstats
path: root/Modules/_sqlite/microprotocols.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2023-07-12 05:57:10 (GMT)
committerGitHub <noreply@github.com>2023-07-12 05:57:10 (GMT)
commitbe1b968dc1e63c3c68e161ddc5a05eb064833440 (patch)
tree8689ba9f656854b83bf24b82de4fc471437a51ab /Modules/_sqlite/microprotocols.c
parente8ab0096a583184fe24dfbc39eff70d270c8e6f4 (diff)
downloadcpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.zip
cpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.tar.gz
cpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.tar.bz2
gh-106521: Remove _PyObject_LookupAttr() function (GH-106642)
Diffstat (limited to 'Modules/_sqlite/microprotocols.c')
-rw-r--r--Modules/_sqlite/microprotocols.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/_sqlite/microprotocols.c b/Modules/_sqlite/microprotocols.c
index 148220d..92f0148 100644
--- a/Modules/_sqlite/microprotocols.c
+++ b/Modules/_sqlite/microprotocols.c
@@ -98,7 +98,7 @@ pysqlite_microprotocols_adapt(pysqlite_state *state, PyObject *obj,
}
/* try to have the protocol adapt this object */
- if (_PyObject_LookupAttr(proto, state->str___adapt__, &adapter) < 0) {
+ if (PyObject_GetOptionalAttr(proto, state->str___adapt__, &adapter) < 0) {
return NULL;
}
if (adapter) {
@@ -117,7 +117,7 @@ pysqlite_microprotocols_adapt(pysqlite_state *state, PyObject *obj,
}
/* and finally try to have the object adapt itself */
- if (_PyObject_LookupAttr(obj, state->str___conform__, &adapter) < 0) {
+ if (PyObject_GetOptionalAttr(obj, state->str___conform__, &adapter) < 0) {
return NULL;
}
if (adapter) {