$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [Boost-users] [Asio] [Boost.ASIO] async_read cannot read full data from client
From: Bjorn Reese (breese_at_[hidden])
Date: 2015-07-29 05:12:31
On 07/29/2015 06:28 AM, Sarvagya Pant wrote:
> I think in my case the buffer is not full, thus the handler function is
> not getting called. How should I change my code so that server can read
> the message sent by client, process it and send back correct response.?
It is easiest to introduce a message separator into your wire protocol.
For instance, you could terminate each message with a newline. Then you
can use async_read_until().