summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllan Saddi <allan@saddi.com>2005-09-08 01:31:01 +0000
committerAllan Saddi <allan@saddi.com>2005-09-08 01:31:01 +0000
commit979c0fc38d7f33c3a0ce151a7958afd63d599e0b (patch)
treea8f1318e4aad41aa1d60b4adf29c6a0515f9f58c
parentb568581723b0bc142f7df85ae0acdc4ae08c0339 (diff)
downloadflup-979c0fc38d7f33c3a0ce151a7958afd63d599e0b.tar.gz
Python 2.3 doesn't define socket.SHUT_WR, which affected
the closing of the FastCGI socket with the server.
-rw-r--r--ChangeLog8
-rw-r--r--flup/server/fcgi_base.py4
2 files changed, 12 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index d555a7a..72b1b19 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2005-09-07 Allan Saddi <asaddi@europa.saddi.net>
+
+ * Python 2.3 doesn't define socket.SHUT_WR, which affected
+ the closing of the FastCGI socket with the server. This would
+ cause output to hang. Thanks to Eugene Lazutkin for bringing
+ the problem to my attention and going out of his way to help
+ me debug it!
+
2005-07-03 Allan Saddi <asaddi@europa.saddi.net>
* Ensure session identifiers only contain ASCII characters when
diff --git a/flup/server/fcgi_base.py b/flup/server/fcgi_base.py
index c09ab5c..32bc75c 100644
--- a/flup/server/fcgi_base.py
+++ b/flup/server/fcgi_base.py
@@ -46,6 +46,10 @@ except ImportError:
import dummy_threading as threading
thread_available = False
+# Apparently 2.3 doesn't define SHUT_WR? Assume it is 1 in this case.
+if not hasattr(socket, 'SHUT_WR'):
+ socket.SHUT_WR = 1
+
__all__ = ['BaseFCGIServer']
# Constants from the spec.