home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Fred Fish Collection 1.5
/
ffcollection-1-5-1992-11.iso
/
ff_progs
/
prog_c
/
zc.lzh
/
ZC
/
ZCSRC.LZH
/
IOLib
/
stdio
/
setbuf.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1988-11-09
|
332 b
|
21 lines
#include <stdio.h>
void setbuf(fp, buf)
register FILE *fp;
unsigned char *buf;
{
fp->_flag &= ~(_IOFBF | _IOLBF | _IONBF | _IOMYBUF);
fp->_cnt = 0;
fp->_ptr = buf;
if(fp->_base = buf) /* assignment intentional */
{
fp->_flag |= _IOFBF;
fp->_bsiz = BUFSIZ;
}
else
{
fp->_flag |= _IONBF;
fp->_bsiz = 0;
}
}