tighten up except - only ValueError can be raised in this situation

This commit is contained in:
Skip Montanaro 2002-03-23 05:50:17 +00:00
parent 3c643d8db3
commit db5d1444a1
1 changed files with 1 additions and 1 deletions

View File

@ -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'