Boost Users :
Subject: Re: [Boost-users] asio ip::tcp::socket::read(), always returns end of file
From: Lloyd (lloydkl.tech_at_[hidden])
Date: 2011-06-06 08:54:20
Thanks Igor. So I was debugging a problem that doesn't exist :(
On Mon, Jun 6, 2011 at 4:40 PM, Igor R <boost.lists_at_[hidden]> wrote:
>> catch(exception& e)
>> cout<<e.what()<<endl; //"This exception is thrown always-> "End of file"
> So your peer sends some data and closes the socket.
> asio::read() reads this data, and then throws the exception. What
> behavior would you expect?
> Please note that this is the *only* way this overload can complete.
> Otherwise, it would just block forever.
> Boost-users mailing list
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net