From 72ce85823cb9da79aa2663fd5d6eeecb3dad7b9c Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Fri, 12 Feb 1999 14:13:10 +0000 Subject: Fix by Chris Petrilli (to his own code) to limit the number of iterations looking for expansions to 10. --- Lib/ConfigParser.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Lib/ConfigParser.py b/Lib/ConfigParser.py index bc646e4..dd8b6d8 100644 --- a/Lib/ConfigParser.py +++ b/Lib/ConfigParser.py @@ -209,7 +209,9 @@ class ConfigParser: return rawval value = rawval # Make it a pretty variable name - while 1: # Loop through this until it's done + depth = 0 + while depth < 10: # Loop through this until it's done + depth = depth + 1 if not string.find(value, "%("): try: value = value % d -- cgit v0.12