![]() |
![]()
| ![]() |
![]()
NAMExt_ff_write() - Write a fixed number of bytes to a fast file stream LIBRARY#include <xtend/fast-file.h> -lxtend SYNOPSISsize_t xt_ff_write(xt_ff_t *stream, void * ptr, size_t size, size_t nmemb) ARGUMENTSstream Pointer to an xt_ff_t structure ptr Memory location from which data are written size Size of one object being read nmemb Number of objects to read DESCRIPTIONxt_ff_write(3) writes a fixed number of bytes (size * nmemb) to stream from address ptr, which should point to an object (if nmemb == 1) or array of "nmemb" objects of size "size". RETURN VALUESThe number of objects (not bytes) successfully written EXAMPLESmy_type_t list[NUM_OBJECTS]; xt_ff_t *stream; stream = xt_ff_open("myfile", O_RDONLY); xt_ff_write(stream, list, sizeof(my_type_t), NUM_OBJECTS); SEE ALSOxt_ff_read(2), xt_ff_open(3), write(2)
|