diff options
| author | Serhiy Storchaka <storchaka@gmail.com> | 2023-07-12 05:57:10 (GMT) |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-12 05:57:10 (GMT) |
| commit | be1b968dc1e63c3c68e161ddc5a05eb064833440 (patch) | |
| tree | 8689ba9f656854b83bf24b82de4fc471437a51ab /Objects/fileobject.c | |
| parent | e8ab0096a583184fe24dfbc39eff70d270c8e6f4 (diff) | |
| download | cpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.zip cpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.tar.gz cpython-be1b968dc1e63c3c68e161ddc5a05eb064833440.tar.bz2 | |
gh-106521: Remove _PyObject_LookupAttr() function (GH-106642)
Diffstat (limited to 'Objects/fileobject.c')
| -rw-r--r-- | Objects/fileobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/fileobject.c b/Objects/fileobject.c index 6d980a1..751fb69 100644 --- a/Objects/fileobject.c +++ b/Objects/fileobject.c @@ -176,7 +176,7 @@ PyObject_AsFileDescriptor(PyObject *o) if (PyLong_Check(o)) { fd = _PyLong_AsInt(o); } - else if (_PyObject_LookupAttr(o, &_Py_ID(fileno), &meth) < 0) { + else if (PyObject_GetOptionalAttr(o, &_Py_ID(fileno), &meth) < 0) { return -1; } else if (meth != NULL) { |
