diff options
Diffstat (limited to 'Parser/parsetok.c')
-rw-r--r-- | Parser/parsetok.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Parser/parsetok.c b/Parser/parsetok.c index 5b0d990..6d20d93 100644 --- a/Parser/parsetok.c +++ b/Parser/parsetok.c @@ -192,7 +192,7 @@ parsetok(tok, g, start, err_ret) err_ret->offset = tok->cur - tok->buf; if (tok->buf != NULL) { int len = tok->inp - tok->buf; - err_ret->text = malloc(len + 1); + err_ret->text = PyMem_NEW(char, len + 1); if (err_ret->text != NULL) { if (len > 0) strncpy(err_ret->text, tok->buf, len); |