![]() |
![]()
| ![]() |
![]()
NAME_xt_ff_raw_close() - Close a stream created by _xt_ff_raw_open() LIBRARY#include <xtend/fast-file.h> -lxtend SYNOPSISint _xt_ff_raw_close(xt_ff_t *stream) ARGUMENTSstream Pointer to an xt_ff_t object opened by xt_ff_open(3) DESCRIPTION_xt_ff_raw_close(3) closes a xt_ff_t stream opened by _xt_ff_raw_open(3). It writes out any remaining data in the output buffer, deallocates memory allocated by xt_ff_open(3), and closes the underlying file descriptor opened by open(3). The xt_ff_t system is simpler than and much faster than traditional FILE on typical systems. It is intended for processing large files character-by-character, where low-level block I/O is not convenient, but FILE I/O causes a bottleneck. RETURN VALUESThe return status of the underlying close(3) call EXAMPLESchar *infilename, *outfilename; xt_ff_t *instream, *outstream; int ch; if ( (instream = xt_ff_open(infilename, O_RDONLY)) == NULL ) { SEE ALSOxt_ff_open(3), xt_ff_getc(3), xt_ff_putc(3)
|