diff options
author | Jeremy Hylton <jeremy@alum.mit.edu> | 2001-01-23 00:50:52 +0000 |
---|---|---|
committer | Jeremy Hylton <jeremy@alum.mit.edu> | 2001-01-23 00:50:52 +0000 |
commit | c795260ceaec0569300e6a3dd81bfe587a16cdd2 (patch) | |
tree | d70c7cab063bd2d9d216e3777438bed6a82d89d1 /Python/compile.c | |
parent | 4d224bf3bf29e7794937149ce12f7900755bf50a (diff) | |
download | cpython-c795260ceaec0569300e6a3dd81bfe587a16cdd2.tar.gz |
prevent symtable_params() from dereferencing off the end of the
varagslist node. based on fix from Thomas Wouters.
Diffstat (limited to 'Python/compile.c')
-rw-r--r-- | Python/compile.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/compile.c b/Python/compile.c index 6ca777e5bb..a9ff3dffdb 100644 --- a/Python/compile.c +++ b/Python/compile.c @@ -4325,6 +4325,8 @@ symtable_params(struct symtable *st, node *n) symtable_add_def(st, STR(CHILD(n, i)), DEF_PARAM | DEF_STAR); i += 2; + if (i >= NCH(n)) + return; c = CHILD(n, i); } if (TYPE(c) == DOUBLESTAR) { |