summaryrefslogtreecommitdiffstats
path: root/Parser/tokenizer.c
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2016-12-06 17:45:50 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2016-12-06 17:45:50 (GMT)
commita5ed5f000aad67d216201d959de4c70b7575309d (patch)
treef30829b98aaada578afe0a9b1dced36e4c0f237f /Parser/tokenizer.c
parent2a358f862bb24ddfb26c45d7e4af87c073d4bc1f (diff)
downloadcpython-a5ed5f000aad67d216201d959de4c70b7575309d.zip
cpython-a5ed5f000aad67d216201d959de4c70b7575309d.tar.gz
cpython-a5ed5f000aad67d216201d959de4c70b7575309d.tar.bz2
Use _PyObject_CallNoArg()
Replace: PyObject_CallObject(callable, NULL) with: _PyObject_CallNoArg(callable)
Diffstat (limited to 'Parser/tokenizer.c')
-rw-r--r--Parser/tokenizer.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Parser/tokenizer.c b/Parser/tokenizer.c
index 0fa3aeb..10639ed 100644
--- a/Parser/tokenizer.c
+++ b/Parser/tokenizer.c
@@ -440,7 +440,7 @@ fp_readl(char *s, int size, struct tok_state *tok)
}
else
{
- bufobj = PyObject_CallObject(tok->decoding_readline, NULL);
+ bufobj = _PyObject_CallNoArg(tok->decoding_readline);
if (bufobj == NULL)
goto error;
}
@@ -533,7 +533,7 @@ fp_setreadl(struct tok_state *tok, const char* enc)
Py_XSETREF(tok->decoding_readline, readline);
if (pos > 0) {
- PyObject *bufobj = PyObject_CallObject(readline, NULL);
+ PyObject *bufobj = _PyObject_CallNoArg(readline);
if (bufobj == NULL)
return 0;
Py_DECREF(bufobj);
@@ -650,7 +650,7 @@ decoding_feof(struct tok_state *tok)
} else {
PyObject* buf = tok->decoding_buffer;
if (buf == NULL) {
- buf = PyObject_CallObject(tok->decoding_readline, NULL);
+ buf = _PyObject_CallNoArg(tok->decoding_readline);
if (buf == NULL) {
error_ret(tok);
return 1;