28 Apr
2003
28 Apr
'03
04:24
On Monday 28 April 2003 03:48, Raúl Gutiérrez Segalés wrote: <snip>
char buf[100];
<snip>
buf[size]='\0';
Enlight me, I only see one, no protection against buffer overflows..
That would be the one. There is a protection against buffer overflows, in that both read and fread state how many bytes they want. Sadly, I wrote it a bit too quickly, and potentially 101 bytes could be put in a 100 byte buffer. Oh well, whaddyawant for a nickel, a rubber biscuit?