MCPcopy Create free account
hub / github.com/boostorg/asio / do_write_message

Method do_write_message

example/cpp11/chat/posix_chat_client.cpp:135–150  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133 }
134
135 void do_write_message()
136 {
137 boost::asio::async_write(socket_,
138 boost::asio::buffer(write_msg_.data(), write_msg_.length()),
139 [this](boost::system::error_code ec, std::size_t /*length*/)
140 {
141 if (!ec)
142 {
143 do_read_input();
144 }
145 else
146 {
147 close();
148 }
149 });
150 }
151
152 void close()
153 {

Callers

nothing calls this directly

Calls 5

async_writeFunction · 0.85
bufferFunction · 0.85
lengthMethod · 0.80
closeFunction · 0.50
dataMethod · 0.45

Tested by

no test coverage detected