Speed up read() (i.e. read till EOF) considerably by doing a stat() to
see if we can guess the #bytes until the end of the file. If we can't, increment the buffer size increments up to 0.5Meg to avoid realloc'ing too much.
Showing
Please
register
or
sign in
to comment