mirror of
https://github.com/python/cpython.git
synced 2025-11-09 22:16:39 +00:00
Fix unterminated keyword array passed to PyArg_ParseTupleAndKeywords
This commit is contained in:
parent
2b88fcf693
commit
c68e1368b5
1 changed files with 2 additions and 2 deletions
|
|
@ -1855,7 +1855,7 @@ treebuilder_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
|
||||||
static int
|
static int
|
||||||
treebuilder_init(PyObject *self, PyObject *args, PyObject *kwds)
|
treebuilder_init(PyObject *self, PyObject *args, PyObject *kwds)
|
||||||
{
|
{
|
||||||
static char *kwlist[] = {"element_factory", NULL};
|
static char *kwlist[] = {"element_factory", 0};
|
||||||
PyObject *element_factory = NULL;
|
PyObject *element_factory = NULL;
|
||||||
TreeBuilderObject *self_tb = (TreeBuilderObject *)self;
|
TreeBuilderObject *self_tb = (TreeBuilderObject *)self;
|
||||||
|
|
||||||
|
|
@ -2762,7 +2762,7 @@ xmlparser_init(PyObject *self, PyObject *args, PyObject *kwds)
|
||||||
XMLParserObject *self_xp = (XMLParserObject *)self;
|
XMLParserObject *self_xp = (XMLParserObject *)self;
|
||||||
PyObject *target = NULL, *html = NULL;
|
PyObject *target = NULL, *html = NULL;
|
||||||
char *encoding = NULL;
|
char *encoding = NULL;
|
||||||
static char *kwlist[] = {"html", "target", "encoding"};
|
static char *kwlist[] = {"html", "target", "encoding", 0};
|
||||||
|
|
||||||
if (!PyArg_ParseTupleAndKeywords(args, kwds, "|OOz:XMLParser", kwlist,
|
if (!PyArg_ParseTupleAndKeywords(args, kwds, "|OOz:XMLParser", kwlist,
|
||||||
&html, &target, &encoding)) {
|
&html, &target, &encoding)) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue