| 82 | } |
| 83 | |
| 84 | void do_write_output() |
| 85 | { |
| 86 | // Write out the message we just received, terminated by a newline. |
| 87 | static char eol[] = { '\n' }; |
| 88 | std::array<boost::asio::const_buffer, 2> buffers = {{ |
| 89 | boost::asio::buffer(read_msg_.body(), read_msg_.body_length()), |
| 90 | boost::asio::buffer(eol) }}; |
| 91 | boost::asio::async_write(output_, buffers, |
| 92 | [this](boost::system::error_code ec, std::size_t /*length*/) |
| 93 | { |
| 94 | if (!ec) |
| 95 | { |
| 96 | do_read_header(); |
| 97 | } |
| 98 | else |
| 99 | { |
| 100 | close(); |
| 101 | } |
| 102 | }); |
| 103 | } |
| 104 | |
| 105 | void do_read_input() |
| 106 | { |
nothing calls this directly
no test coverage detected