@node setbuffer, stdio @subheading Syntax @example #include void setbuffer(FILE *file, char *buffer, int length); @end example @subheading Description This function modifies the buffering characteristics of @var{file}. First, if the file already has a buffer, it is freed. If there was any pending data in it, it is lost, so this function should only be used immediately after a call to @code{fopen}. If the @var{buffer} passed is @code{NULL}, the file is set to unbuffered. If a non-@code{NULL} buffer is passed, it must be at least @var{size} bytes in size, and the file is set to fully buffered. @xref{setbuf}. @xref{setlinebuf}. @xref{setvbuf}. @subheading Return Value None. @subheading Portability @portability !ansi, !posix @subheading Example @example setbuffer(stdout, malloc(10000), 10000); @end example