SHARE
TWEET

Untitled

a guest Jun 16th, 2019 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. client.cpp: In function ‘void on_read(const error_code&, std::size_t)’:
  2. client.cpp:17:50: warning: unused parameter ‘bytes’ [-Wunused-parameter]
  3.  void on_read(const error_code & err, std::size_t bytes) {
  4.                                                   ^~~~~
  5. client.cpp: In function ‘void on_write(const error_code&, std::size_t)’:
  6. client.cpp:25:51: error: no matching function for call to ‘async_read_until(boost::asio::posix::stream_descriptor&, boost::asio::const_buffers_1, char, void (&)(const error_code&, std::size_t))’
  7.      async_read_until(in, buffer(line),'n',on_read);
  8.                                                    ^
  9. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  10.                  from /usr/include/boost/asio.hpp:91,
  11.                  from client.cpp:1:
  12. /usr/include/boost/asio/impl/read_until.hpp:498:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, char, ReadHandler&&)
  13.  async_read_until(AsyncReadStream& s,
  14.  ^~~~~~~~~~~~~~~~
  15. /usr/include/boost/asio/impl/read_until.hpp:498:1: note:   template argument deduction/substitution failed:
  16. client.cpp:25:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  17.      async_read_until(in, buffer(line),'n',on_read);
  18.                                                    ^
  19. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  20.                  from /usr/include/boost/asio.hpp:91,
  21.                  from client.cpp:1:
  22. /usr/include/boost/asio/impl/read_until.hpp:701:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, const string&, ReadHandler&&)
  23.  async_read_until(AsyncReadStream& s,
  24.  ^~~~~~~~~~~~~~~~
  25. /usr/include/boost/asio/impl/read_until.hpp:701:1: note:   template argument deduction/substitution failed:
  26. client.cpp:25:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  27.      async_read_until(in, buffer(line),'n',on_read);
  28.                                                    ^
  29. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  30.                  from /usr/include/boost/asio.hpp:91,
  31.                  from client.cpp:1:
  32. /usr/include/boost/asio/impl/read_until.hpp:913:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, const regex&, ReadHandler&&)
  33.  async_read_until(AsyncReadStream& s,
  34.  ^~~~~~~~~~~~~~~~
  35. /usr/include/boost/asio/impl/read_until.hpp:913:1: note:   template argument deduction/substitution failed:
  36. client.cpp:25:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  37.      async_read_until(in, buffer(line),'n',on_read);
  38.                                                    ^
  39. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  40.                  from /usr/include/boost/asio.hpp:91,
  41.                  from client.cpp:1:
  42. /usr/include/boost/asio/impl/read_until.hpp:1122:1: note: candidate: template<class AsyncReadStream, class Allocator, class MatchCondition, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, MatchCondition, ReadHandler&&, typename std::enable_if<boost::asio::is_match_condition<MatchCondition>::value>::type*)
  43.  async_read_until(AsyncReadStream& s,
  44.  ^~~~~~~~~~~~~~~~
  45. /usr/include/boost/asio/impl/read_until.hpp:1122:1: note:   template argument deduction/substitution failed:
  46. client.cpp:25:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  47.      async_read_until(in, buffer(line),'n',on_read);
  48.                                                    ^
  49. client.cpp:23:34: warning: unused parameter ‘err’ [-Wunused-parameter]
  50.  void on_write(const error_code & err, std::size_t bytes) {
  51.                                   ^~~
  52. client.cpp:23:51: warning: unused parameter ‘bytes’ [-Wunused-parameter]
  53.  void on_write(const error_code & err, std::size_t bytes) {
  54.                                                    ^~~~~
  55. client.cpp: In function ‘int main()’:
  56. client.cpp:29:51: error: no matching function for call to ‘async_read_until(boost::asio::posix::stream_descriptor&, boost::asio::const_buffers_1, char, void (&)(const error_code&, std::size_t))’
  57.      async_read_until(in, buffer(line),'n',on_read);
  58.                                                    ^
  59. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  60.                  from /usr/include/boost/asio.hpp:91,
  61.                  from client.cpp:1:
  62. /usr/include/boost/asio/impl/read_until.hpp:498:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, char, ReadHandler&&)
  63.  async_read_until(AsyncReadStream& s,
  64.  ^~~~~~~~~~~~~~~~
  65. /usr/include/boost/asio/impl/read_until.hpp:498:1: note:   template argument deduction/substitution failed:
  66. client.cpp:29:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  67.      async_read_until(in, buffer(line),'n',on_read);
  68.                                                    ^
  69. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  70.                  from /usr/include/boost/asio.hpp:91,
  71.                  from client.cpp:1:
  72. /usr/include/boost/asio/impl/read_until.hpp:701:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, const string&, ReadHandler&&)
  73.  async_read_until(AsyncReadStream& s,
  74.  ^~~~~~~~~~~~~~~~
  75. /usr/include/boost/asio/impl/read_until.hpp:701:1: note:   template argument deduction/substitution failed:
  76. client.cpp:29:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  77.      async_read_until(in, buffer(line),'n',on_read);
  78.                                                    ^
  79. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  80.                  from /usr/include/boost/asio.hpp:91,
  81.                  from client.cpp:1:
  82. /usr/include/boost/asio/impl/read_until.hpp:913:1: note: candidate: template<class AsyncReadStream, class Allocator, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, const regex&, ReadHandler&&)
  83.  async_read_until(AsyncReadStream& s,
  84.  ^~~~~~~~~~~~~~~~
  85. /usr/include/boost/asio/impl/read_until.hpp:913:1: note:   template argument deduction/substitution failed:
  86. client.cpp:29:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  87.      async_read_until(in, buffer(line),'n',on_read);
  88.                                                    ^
  89. In file included from /usr/include/boost/asio/read_until.hpp:921:0,
  90.                  from /usr/include/boost/asio.hpp:91,
  91.                  from client.cpp:1:
  92. /usr/include/boost/asio/impl/read_until.hpp:1122:1: note: candidate: template<class AsyncReadStream, class Allocator, class MatchCondition, class ReadHandler> typename boost::asio::async_result<typename boost::asio::handler_type<WriteHandler, void(boost::system::error_code, long unsigned int)>::type>::type boost::asio::async_read_until(AsyncReadStream&, boost::asio::basic_streambuf<Allocator>&, MatchCondition, ReadHandler&&, typename std::enable_if<boost::asio::is_match_condition<MatchCondition>::value>::type*)
  93.  async_read_until(AsyncReadStream& s,
  94.  ^~~~~~~~~~~~~~~~
  95. /usr/include/boost/asio/impl/read_until.hpp:1122:1: note:   template argument deduction/substitution failed:
  96. client.cpp:29:51: note:   ‘boost::asio::const_buffers_1’ is not derived from ‘boost::asio::basic_streambuf<Allocator>’
  97.      async_read_until(in, buffer(line),'n',on_read);
  98.                                                    ^
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top