diff options
author | Benjamin Peterson <benjamin@python.org> | 2010-12-07 04:04:02 (GMT) |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2010-12-07 04:04:02 (GMT) |
commit | 9b955de76f351f260929a1ff7bddfacbdb60d88e (patch) | |
tree | 8c2b19b8e315d940c4aae522382e5ed0aacb1d06 /Objects | |
parent | 9b4e27e8c626087759b12bb6fede30742c683e6a (diff) | |
download | cpython-9b955de76f351f260929a1ff7bddfacbdb60d88e.zip cpython-9b955de76f351f260929a1ff7bddfacbdb60d88e.tar.gz cpython-9b955de76f351f260929a1ff7bddfacbdb60d88e.tar.bz2 |
use the more direct API
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/descrobject.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Objects/descrobject.c b/Objects/descrobject.c index de065b4..9671102 100644 --- a/Objects/descrobject.c +++ b/Objects/descrobject.c @@ -1190,7 +1190,7 @@ property_descr_get(PyObject *self, PyObject *obj, PyObject *type) PyErr_SetString(PyExc_AttributeError, "unreadable attribute"); return NULL; } - return PyObject_CallFunction(gs->prop_get, "(O)", obj); + return PyObject_CallFunctionObjArgs(gs->prop_get, obj, NULL); } static int @@ -1211,9 +1211,9 @@ property_descr_set(PyObject *self, PyObject *obj, PyObject *value) return -1; } if (value == NULL) - res = PyObject_CallFunction(func, "(O)", obj); + res = PyObject_CallFunctionObjArgs(func, obj, NULL); else - res = PyObject_CallFunction(func, "(OO)", obj, value); + res = PyObject_CallFunctionObjArgs(func, obj, value, NULL); if (res == NULL) return -1; Py_DECREF(res); |