I'm working on an editor (mostly to get hang of file/string handling) and I've run into this problem: When I read, say 20 bytes from a file using read(), and the file contains like 5 bytes, the remaining 15 bytes of the string comes of gibberish. Is there a way to get around this?
Thanks.