v7 man page for setbuf

Query: setbuf

OS: v7

Section: 3s

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

SETBUF(3S)																SETBUF(3S)

NAME
setbuf - assign buffering to a stream
SYNOPSIS
#include <stdio.h> setbuf(stream, buf) FILE *stream; char *buf;
DESCRIPTION
Setbuf is used after a stream has been opened but before it is read or written. It causes the character array buf to be used instead of an automatically allocated buffer. If buf is the constant pointer NULL, input/output will be completely unbuffered. A manifest constant BUFSIZ tells how big an array is needed: char buf[BUFSIZ]; A buffer is normally obtained from malloc(3) upon the first getc or putc(3) on the file, except that output streams directed to terminals, and the standard error stream stderr are normally not buffered.
SEE ALSO
fopen(3), getc(3), putc(3), malloc(3) SETBUF(3S)
Related Man Pages
setbuf(3c) - opensolaris
setbuffer(3c) - opensolaris
setbuf(3s) - ultrix
setbuffer(3s) - ultrix
setlinebuf(3s) - ultrix
Similar Topics in the Unix Linux Community
Top v3.7 and v3.8beta1 will not compile on Power7/AIX6.1 server.
Segment Violation
Masking Password with *'s
Forcing a write to a file without newline?