3 ms·
So, you take a `\r` from the network. So, do you wait for a `\n` before returning the line?
by marcosdumay 8y ago
So, you take a `\r` from the network. So, do you wait for a `\n` before returning the line?
- rhencke 8y agoYou wait to peek the next byte, or EOF, and then make the choice.
- marcosdumay 8y agoLine protocols do not transmit EOF (and the problem is on each line anyway). And the next byte may only come after you write something on the socket.