diff options
| author | Victor Stinner <vstinner@python.org> | 2020-02-07 00:38:59 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-02-07 00:38:59 +0100 |
| commit | a93c51e3a8e15f1a486d11d5b55a64f3381babe0 (patch) | |
| tree | a84997f6ca55cb27c92248dc04eda44e01a07a2a /Objects/fileobject.c | |
| parent | 446463f8dbce0556be8020914f37089b63bb8ab6 (diff) | |
| download | cpython-git-a93c51e3a8e15f1a486d11d5b55a64f3381babe0.tar.gz | |
bpo-39573: Use Py_REFCNT() macro (GH-18388)
Replace direct acccess to PyObject.ob_refcnt with usage of the
Py_REFCNT() macro.
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 527693c809..c0eff8bed5 100644 --- a/Objects/fileobject.c +++ b/Objects/fileobject.c @@ -85,7 +85,7 @@ PyFile_GetLine(PyObject *f, int n) "EOF when reading a line"); } else if (s[len-1] == '\n') { - if (result->ob_refcnt == 1) + if (Py_REFCNT(result) == 1) _PyBytes_Resize(&result, len-1); else { PyObject *v; |
