projects
/
python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2ae3c91
)
Remove C99ism.
author
Martin v. Löwis
<martin@v.loewis.de>
Wed, 15 Feb 2006 19:56:18 +0000
(19:56 +0000)
committer
Martin v. Löwis
<martin@v.loewis.de>
Wed, 15 Feb 2006 19:56:18 +0000
(19:56 +0000)
Parser/parsetok.c
patch
|
blob
|
history
diff --git
a/Parser/parsetok.c
b/Parser/parsetok.c
index 48236a7028ee323932feb88456e875711a03012b..4c533f10e116d6248f5789faaaabde6b4f4e148f 100644
(file)
--- a/
Parser/parsetok.c
+++ b/
Parser/parsetok.c
@@
-186,9
+186,10
@@
parsetok(struct tok_state *tok, grammar *g, int start, perrdetail *err_ret,
err_ret->error = E_EOF;
err_ret->lineno = tok->lineno;
if (tok->buf != NULL) {
+ size_t len;
assert(tok->cur - tok->buf < INT_MAX);
err_ret->offset = (int)(tok->cur - tok->buf);
-
size_t
len = tok->inp - tok->buf;
+ len = tok->inp - tok->buf;
err_ret->text = (char *) PyObject_MALLOC(len + 1);
if (err_ret->text != NULL) {
if (len > 0)