summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSenthil Kumaran <senthil@uthcode.com>2011-05-11 08:04:28 (GMT)
committerSenthil Kumaran <senthil@uthcode.com>2011-05-11 08:04:28 (GMT)
commitcc99528d872e0f8a87a762a990beb9e3755cbb42 (patch)
treeadbd396ec18cfa324c83b6a39d4aefcf313ccfdf
parent6ea17a88afbd3ba9f30b4baa071d77dd1a5070fb (diff)
downloadcpython-cc99528d872e0f8a87a762a990beb9e3755cbb42.zip
cpython-cc99528d872e0f8a87a762a990beb9e3755cbb42.tar.gz
cpython-cc99528d872e0f8a87a762a990beb9e3755cbb42.tar.bz2
issue12039 - update the documentation of send_response method in http.server.rst.
-rw-r--r--Doc/library/http.server.rst15
1 files changed, 11 insertions, 4 deletions
diff --git a/Doc/library/http.server.rst b/Doc/library/http.server.rst
index e77e81d..17ea18a 100644
--- a/Doc/library/http.server.rst
+++ b/Doc/library/http.server.rst
@@ -180,10 +180,17 @@ of which this module provides three different variants:
.. method:: send_response(code, message=None)
Adds a response header to the headers buffer and logs the accepted
- request. The HTTP response line is sent, followed by *Server* and
- *Date* headers. The values for these two headers are picked up from
- the :meth:`version_string` and :meth:`date_time_string` methods,
- respectively.
+ request. The HTTP response line is written to the internal buffer,
+ followed by *Server* and *Date* headers. The values for these two headers
+ are picked up from the :meth:`version_string` and
+ :meth:`date_time_string` methods, respectively. If the server does not
+ intend to send any other headers using the :meth:`send_header` method,
+ then send_response should be followed by a :meth:`end_headers` call.
+
+ ..versionchanged:: 3.3
+ Writing of headers to internal buffer and need to call
+ :meth:`end_headers` explicitly.
+
.. method:: send_header(keyword, value)