Read from a binary stream.
- ptr
- Where to store the binary data read.
- size
- The size of each object to read.
- nmemb
- The number of objects to read.
- stream
- The binary FILE stream to read from.
The function fread() advances the file position indicator for the stream by the number of bytes read. It returns the number of objects read or written. If an error occurs, or the end-of-file is reached, the return value is a short object count (or zero).
The function fread() does not distinguish between end-of-file and error, and callers must use Stdlib.feof(3) and Stdlib.ferror(3) to determine which occurred.
The function fread() reads nmemb objects, each size bytes long, from the stream pointed to by stream, storing them at the location given by ptr.
Namespace: Mono.Unix.Native
Assembly: Mono.Posix (in Mono.Posix.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0