summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2011-05-24 17:09:26 (GMT)
committerBenjamin Peterson <benjamin@python.org>2011-05-24 17:09:26 (GMT)
commit48e21fc46f3348c987d671ac4068a03c169ea801 (patch)
tree296427ad211c9973981c7ff428e10170b8c95e9f
parentcf057597e6d91c93dbb8bf63e1151d2b2da580d5 (diff)
parenta7cdb0f218b991f7d8c8f45af0e4f975673ee351 (diff)
downloadcpython-48e21fc46f3348c987d671ac4068a03c169ea801.zip
cpython-48e21fc46f3348c987d671ac4068a03c169ea801.tar.gz
cpython-48e21fc46f3348c987d671ac4068a03c169ea801.tar.bz2
merge 3.1
-rw-r--r--Lib/socketserver.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/socketserver.py b/Lib/socketserver.py
index f42802c..1103f4b 100644
--- a/Lib/socketserver.py
+++ b/Lib/socketserver.py
@@ -552,15 +552,16 @@ class ForkingMixIn:
else:
# Child process.
# This must never return, hence os._exit()!
- self.socket.close()
try:
self.finish_request(request, client_address)
self.shutdown_request(request)
+ self.socket.close()
os._exit(0)
except:
try:
self.handle_error(request, client_address)
self.shutdown_request(request)
+ self.socket.close()
finally:
os._exit(1)