LOGIN • JOININ

JunRyoung Ju

```
void do_write()
{
auto self(shared_from_this());
boost::asio::async_write(socket_,
boost::asio::buffer(write_msgs_.front().data(),
write_msgs_.front().length()),
[this, self](boost::system::error_code ec, std::size_t /*length*/)
{
if (!ec)
{
EnterCriticalSection(&csqueue_);

write_msgs_.pop_front();
if (!write_msgs_.empty())
{
do_write();
}

LeaveCriticalSection(&csqueue_);
}
else
{
}
});
}
```

재귀함수로 계속해서 async안에 async, async, async을 생성하고있습니다.