c++ - I don't understand why boost::asio::read_until reads characters behind the delimiter -


according boost::asio::read_until documentation:

after successful read_until operation, streambuf may contain additional data beyond delimiter. application typically leave data in streambuf subsequent read_until operation examine.

i not understand why happens.

is because, in tcp protocol, if not read available characters, can lose them?

because if read until character want, have perform 1 one-character read @ time. horribly inefficient.


Comments

Popular posts from this blog

javascript - Create a stacked percentage column -

Optimising Firebase database by automatically overwriting data -

javascript - Angular UI-Grid customTemplate directive causing rows to load slowly/? -