From: Skip Montanaro Date: Sat, 23 Mar 2002 05:50:17 +0000 (+0000) Subject: tighten up except - only ValueError can be raised in this situation X-Git-Tag: v2.3c1~6381 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=db5d1444a1e2b0235634fcd307a7f960e66b02b0;p=thirdparty%2FPython%2Fcpython.git tighten up except - only ValueError can be raised in this situation --- diff --git a/Lib/cgi.py b/Lib/cgi.py index 823dde2b6ea8..db91ec6d2e44 100755 --- a/Lib/cgi.py +++ b/Lib/cgi.py @@ -506,7 +506,7 @@ class FieldStorage: if self.headers.has_key('content-length'): try: clen = int(self.headers['content-length']) - except: + except ValueError: pass if maxlen and clen > maxlen: raise ValueError, 'Maximum content length exceeded'