* python/py-value.c (valpy_string): NULL-terminate 'keywords'.

This commit is contained in:
Tom Tromey 2009-09-29 15:13:45 +00:00
parent 464d3bd458
commit 31158f0e2a
2 changed files with 5 additions and 1 deletions

View file

@ -239,7 +239,7 @@ valpy_string (PyObject *self, PyObject *args, PyObject *kw)
const char *user_encoding = NULL;
const char *la_encoding = NULL;
struct type *char_type;
static char *keywords[] = { "encoding", "errors", "length" };
static char *keywords[] = { "encoding", "errors", "length", NULL };
if (!PyArg_ParseTupleAndKeywords (args, kw, "|ssi", keywords,
&user_encoding, &errors, &length))