Reads a specified number of bytes from a file to a buffer.
int INKfread (INKFile
filep
, void
*buf
, int
length
)
is the file
to read from.filep
is the buffer
to read into.buf
is the
amount of data to read.length
Attempts to read
bytes of data
from the file pointed to by
length
into the buffer
filep
. If the file was not
opened for reading, then buf
returns INKfread
-1
. If an error occurs while reading the file, then
returns INKfread
-1
. If the
end of the file is reached, then INKfread
returns 0
; otherwise, INKfread
returns the
number of bytes read.
See the example for INKfopen