Jesus Cea wrote: > How do you differenciate between that empty string (when doing > "read(0)"), from EOF (that is signaled by an empty string)?. If you need to be able to make that distinction, then you have to be careful not to try to read 0 bytes. Personally I've never come across a situation where allowing read(0) to occur would have simplified the code. In the usual keep-reading-until-we've-got-the- required-number-of-bytes scenario, you're checking for 0 bytes left to read in order to tell when to stop. -- Greg
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4