diff options
author | Guido van Rossum <guido@python.org> | 2000-09-01 03:27:34 +0000 |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2000-09-01 03:27:34 +0000 |
commit | a62e2ec8a7b06b1477186ef0229794ea955957c0 (patch) | |
tree | 45b1546f7e1e25fee129fe5aedbdee718964db58 /Lib/CGIHTTPServer.py | |
parent | 5f742e02f544e8fb664662b80a1a6779d865f15f (diff) | |
download | cpython-a62e2ec8a7b06b1477186ef0229794ea955957c0.tar.gz |
Now that StreamRequestHandler defaults rfile to buffered, make it
unbuffered (by setting the class variable rbufsize to 0), because we
(may) need to pass the file descriptor to the subprocess running the
CGI script positioned after the headers.
Diffstat (limited to 'Lib/CGIHTTPServer.py')
-rw-r--r-- | Lib/CGIHTTPServer.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/CGIHTTPServer.py b/Lib/CGIHTTPServer.py index fa30cbddda..6a259a32da 100644 --- a/Lib/CGIHTTPServer.py +++ b/Lib/CGIHTTPServer.py @@ -35,6 +35,10 @@ class CGIHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler): """ + # Make rfile unbuffered -- we need to read one line and then pass + # the rest to a subprocess, so we can't use buffered input. + rbufsize = 0 + def do_POST(self): """Serve a POST request. |