Boost logo

Boost-Commit :

From: chris_at_[hidden]
Date: 2007-08-20 09:53:28


Author: chris_kohlhoff
Date: 2007-08-20 09:53:27 EDT (Mon, 20 Aug 2007)
New Revision: 38783
URL: http://svn.boost.org/trac/boost/changeset/38783

Log:
Add a note to basic_socket<>::close() indicating that shutdown() should
be used for portable graceful closure.

Text files modified:
   trunk/boost/asio/basic_socket.hpp | 6 ++++++
   1 files changed, 6 insertions(+), 0 deletions(-)

Modified: trunk/boost/asio/basic_socket.hpp
==============================================================================
--- trunk/boost/asio/basic_socket.hpp (original)
+++ trunk/boost/asio/basic_socket.hpp 2007-08-20 09:53:27 EDT (Mon, 20 Aug 2007)
@@ -239,6 +239,9 @@
    * with the boost::asio::error::operation_aborted error.
    *
    * @throws boost::system::system_error Thrown on failure.
+ *
+ * @note For portable behaviour with respect to graceful closure of a
+ * connected socket, call shutdown() before closing the socket.
    */
   void close()
   {
@@ -266,6 +269,9 @@
    * // An error occurred.
    * }
    * @endcode
+ *
+ * @note For portable behaviour with respect to graceful closure of a
+ * connected socket, call shutdown() before closing the socket.
    */
   boost::system::error_code close(boost::system::error_code& ec)
   {


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk