commit | 209307eb3bca9aeb9b842014edcfe8df9cbb7f91 | [log] [tgz] |
---|---|---|
author | Georg Brandl <georg@python.org> | Wed Aug 09 07:03:22 2006 +0000 |
committer | Georg Brandl <georg@python.org> | Wed Aug 09 07:03:22 2006 +0000 |
tree | c5cd1f4876045284dcbf4144d591602c31b59650 | |
parent | 8e24a9678f497ef40b01040d29ff260337da1e77 [diff] [blame] |
Introduce an upper bound on tuple nesting depth in C argument format strings; fixes rest of #1523610.
diff --git a/Python/getargs.c b/Python/getargs.c index 508055e..3fca9cd 100644 --- a/Python/getargs.c +++ b/Python/getargs.c
@@ -206,6 +206,9 @@ if (level == 0) max++; level++; + if (level >= 30) + Py_FatalError("too many tuple nesting levels " + "in argument format string"); break; case ')': if (level == 0)