[Python-checkins] cpython (merge 3.2 -> default): merge from 3.2. Issue #13073 - Address the review comments made by Ezio.

senthil.kumaran python-checkins at python.org
Wed Oct 5 17:27:52 CEST 2011


http://hg.python.org/cpython/rev/a7b7ba225de7
changeset:   72693:a7b7ba225de7
parent:      72691:c2127d79f7c1
parent:      72692:befa7b926aad
user:        Senthil Kumaran <senthil at uthcode.com>
date:        Wed Oct 05 23:27:37 2011 +0800
summary:
  merge from 3.2. Issue  #13073 - Address the review comments made by Ezio.

files:
  Doc/library/http.client.rst |   9 ++++-----
  Lib/http/client.py          |  10 +++++-----
  2 files changed, 9 insertions(+), 10 deletions(-)


diff --git a/Doc/library/http.client.rst b/Doc/library/http.client.rst
--- a/Doc/library/http.client.rst
+++ b/Doc/library/http.client.rst
@@ -475,11 +475,10 @@
 .. method:: HTTPConnection.endheaders(message_body=None)
 
    Send a blank line to the server, signalling the end of the headers. The
-   optional message_body argument can be used to pass message body
-   associated with the request.  The message body will be sent in
-   the same packet as the message headers if possible.  The
-   message_body should be a string.
-
+   optional *message_body* argument can be used to pass a message body
+   associated with the request.  The message body will be sent in the same
+   packet as the message headers if it is string, otherwise it is sent in a
+   separate packet.
 
 .. method:: HTTPConnection.send(data)
 
diff --git a/Lib/http/client.py b/Lib/http/client.py
--- a/Lib/http/client.py
+++ b/Lib/http/client.py
@@ -947,11 +947,11 @@
     def endheaders(self, message_body=None):
         """Indicate that the last header line has been sent to the server.
 
-        This method sends the request to the server.  The optional
-        message_body argument can be used to pass message body
-        associated with the request.  The message body will be sent in
-        the same packet as the message headers if possible.  The
-        message_body should be a string.
+        This method sends the request to the server.  The optional message_body
+        argument can be used to pass a message body associated with the
+        request.  The message body will be sent in the same packet as the
+        message headers if it is a string, otherwise it is sent as a separate
+        packet.
         """
         if self.__state == _CS_REQ_STARTED:
             self.__state = _CS_REQ_SENT

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list