From 3c643d8db3dbf58b9a75462d15359573964c57c7 Mon Sep 17 00:00:00 2001 From: Skip Montanaro Date: Sat, 23 Mar 2002 05:47:31 +0000 Subject: tighten up except - int() only raises ValueError --- Lib/CGIHTTPServer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/CGIHTTPServer.py b/Lib/CGIHTTPServer.py index 7a7e075..7bb7467 100644 --- a/Lib/CGIHTTPServer.py +++ b/Lib/CGIHTTPServer.py @@ -235,7 +235,7 @@ class CGIHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler): self.log_message("command: %s", cmdline) try: nbytes = int(length) - except: + except ValueError: nbytes = 0 files = popenx(cmdline, 'b') fi = files[0] -- cgit v0.12