简体   繁体   中英

What causes asio.misc.3 error in boost C++ asio

I am asking this question because I could not find the answer on stack overflow but have answered it myself so hope some future poor soul can benefit.

The context of the problem is when using boost::asio::async_read_until which reads until it encounters a specific string specified in the call. In my vase it was a "/n"

It turns out that the test server that was writing to the socket missed appending "/n" to the records. So the error asio.misc.3 means "Not found" which you can find in the boost source code but it was not immediately obvious what it meant. Obvious in retrospect, of course.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM