zkFwrite - binary output
#include "zkStdio.h"
size_t zkFwrite(const void* ptr, size_t size, size_t nitems, FILE* stream);
The zkFwrite() function writes, from the array pointed to by ptr, up to nitems members whose size is specified by size, to the stream pointed to by stream. The file-position indicator for the stream (if defined) is advanced by the number of bytes successfully written. If an error occurs, the resulting value of the file-position indicator for the stream is indeterminate.
The zkFwrite() function returns the number of members successfully written, which may be less than nitems if a write error is encountered. If size or nitems is 0, zkFwrite() returns 0 and the state of the stream remains unchanged. Otherwise, if a write error occurs, the error indicator for the stream is set and errno is set to indicate the error.
Refer to zkFputc().
Because of possible differences in member length and byte ordering, files written using zkFwrite() are application-dependent, and possibly cannot be read using zkFread() by a different application or by the same application on a different processor.