Boost logo

Boost Users :

Subject: Re: [Boost-users] [boost::asio]about boost::asio::async_read_until
From: Igor R (boost.lists_at_[hidden])
Date: 2008-11-24 11:08:31


Sorry, I didn't pay attention that you try to use transfer_all as a
MatchCondition, while it is not MatchCondition.

2008/11/24 Ken zhang <kennir_at_[hidden]>

> Hi lgor R
>
> The handle_read_response is member function of http_connection like this.
>
>
> void http_connection::handle_read_response(const
> boost::system::error_code& e,size_t bytes_transferred)
> {
> .....
> }
>
> BTW: My compiler is MSVC 8.0.
> BOOST version 1.36
>
> Thanks
>
> Ken
>
>
>
>
> 2008/11/24 Igor R <boost.lists_at_[hidden]>
>
>> Hi,
>>
>> What's the signature of http_connection::handle_read_response ?
>>
>>
>>
>>>
>>> I want use async_read_until for read stream from socket until EOF,but I
>>> can't compile code below.
>>>
>>>
>>> code:
>>> boost::asio::async_read_until(socket_,
>>> stream_buffer_,boost::asio::transfer_all(),
>>> boost::bind(&http_connection::handle_read_response, this,
>>>
>>> boost::asio::placeholders::error,boost::asio::placeholders::bytes_transferred));
>>>
>>> stream_buffer is instance of boost::asio::streambuf
>>>
>>> I got the error like:
>>>
>>> d:\development\boost_1_36_0\boost\asio\impl\read_until.ipp(953) : error
>>> C2664: "bool boost::asio::detail::transfer_all_t::operator
>>> ()<iterator>(const Error &,size_t)":Can't convert paramerater 2 from
>>> "iterator" to "size_t"
>>>
>>
>> _______________________________________________
>> Boost-users mailing list
>> Boost-users_at_[hidden]
>> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>>
>
>
>
> --
> Best Regards,
>
> Ken Zhang
> Greatelsoft Co., Ltd.
> mailto:ken_at_[hidden]
> http://www.greatelsoft.com
> M/P:0086-1350-191-6596
>
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>



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