summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Python/bltinmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index 29804f5..0309f1de 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -1806,7 +1806,7 @@ builtin_sum(PyObject *self, PyObject *args)
PyObject *result = NULL;
PyObject *temp, *item, *iter;
- if (!PyArg_ParseTuple(args, "O|O:sum", &seq, &result))
+ if (!PyArg_UnpackTuple(args, "sum", 1, 2, &seq, &result))
return NULL;
iter = PyObject_GetIter(seq);