diff options
author | Jeroen Demeyer <J.Demeyer@UGent.be> | 2019-07-04 10:31:34 (GMT) |
---|---|---|
committer | Inada Naoki <songofacandy@gmail.com> | 2019-07-04 10:31:34 (GMT) |
commit | 196a530e00d88a138973bf9182e013937e293f97 (patch) | |
tree | 35443abb5aa148b459f68ae43a18cdbb0627ba76 /Modules/_xxtestfuzz/fuzzer.c | |
parent | 9d40554e0da09a44a8547f3f3a2b9dedfeaf7928 (diff) | |
download | cpython-196a530e00d88a138973bf9182e013937e293f97.zip cpython-196a530e00d88a138973bf9182e013937e293f97.tar.gz cpython-196a530e00d88a138973bf9182e013937e293f97.tar.bz2 |
bpo-37483: add _PyObject_CallOneArg() function (#14558)
Diffstat (limited to 'Modules/_xxtestfuzz/fuzzer.c')
-rw-r--r-- | Modules/_xxtestfuzz/fuzzer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/_xxtestfuzz/fuzzer.c b/Modules/_xxtestfuzz/fuzzer.c index 16104e4..2446e71 100644 --- a/Modules/_xxtestfuzz/fuzzer.c +++ b/Modules/_xxtestfuzz/fuzzer.c @@ -104,7 +104,7 @@ static int fuzz_json_loads(const char* data, size_t size) { if (input_bytes == NULL) { return 0; } - PyObject* parsed = PyObject_CallFunctionObjArgs(json_loads_method, input_bytes, NULL); + PyObject* parsed = _PyObject_CallOneArg(json_loads_method, input_bytes); if (parsed == NULL) { /* Ignore ValueError as the fuzzer will more than likely generate some invalid json and values */ @@ -263,7 +263,7 @@ static int fuzz_sre_match(const char* data, size_t size) { PyObject* pattern = compiled_patterns[idx]; PyObject* match_callable = PyObject_GetAttrString(pattern, "match"); - PyObject* matches = PyObject_CallFunctionObjArgs(match_callable, to_match, NULL); + PyObject* matches = _PyObject_CallOneArg(match_callable, to_match); Py_XDECREF(matches); Py_DECREF(match_callable); |