commit | 0d6b49eff2bae85a7ea5231e665faafc6e598513 | [log] [tgz] |
---|---|---|
author | Guido van Rossum <guido@python.org> | Mon Jan 19 22:22:44 1998 +0000 |
committer | Guido van Rossum <guido@python.org> | Mon Jan 19 22:22:44 1998 +0000 |
tree | 22e0840bd8f32bf29293267b708789c52f8d5ad1 | |
parent | db9351643dd9019bdbb37dd76710c38b07774ed7 [diff] [blame] |
Protect PyErr_Format format string argument from overflow (ironically, the error was about a bad format string :-).
diff --git a/Python/getargs.c b/Python/getargs.c index 296a3aa..7bc150d 100644 --- a/Python/getargs.c +++ b/Python/getargs.c
@@ -261,7 +261,7 @@ *format != '(' && *format != '|' && *format != ':' && *format != ';') { PyErr_Format(PyExc_SystemError, - "bad format string: %s", formatsave); + "bad format string: %.200s", formatsave); return 0; }