diff options
author | Georg Brandl <georg@python.org> | 2005-08-26 06:43:16 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2005-08-26 06:43:16 (GMT) |
commit | 66e75ac6e092fd1b5b9a7e9378928c9ec0829f32 (patch) | |
tree | 203bed2e39badf89a4bef7e1a281f81192a8097e /Modules/collectionsmodule.c | |
parent | a74a655d816399e1168680c20daff3032665450d (diff) | |
download | cpython-66e75ac6e092fd1b5b9a7e9378928c9ec0829f32.zip cpython-66e75ac6e092fd1b5b9a7e9378928c9ec0829f32.tar.gz cpython-66e75ac6e092fd1b5b9a7e9378928c9ec0829f32.tar.bz2 |
Disallow keyword arguments for type constructors that don't use them
(fixes #1119418).
Diffstat (limited to 'Modules/collectionsmodule.c')
-rw-r--r-- | Modules/collectionsmodule.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Modules/collectionsmodule.c b/Modules/collectionsmodule.c index ed10999..5af568d 100644 --- a/Modules/collectionsmodule.c +++ b/Modules/collectionsmodule.c @@ -95,6 +95,9 @@ deque_new(PyTypeObject *type, PyObject *args, PyObject *kwds) dequeobject *deque; block *b; + if (!_PyArg_NoKeywords("deque()", kwds)) + return NULL; + /* create dequeobject structure */ deque = (dequeobject *)type->tp_alloc(type, 0); if (deque == NULL) |