xref: /csrg-svn/lib/libc/stdio/setbuf.c (revision 46104)
1*46104Sbostic /*-
2*46104Sbostic  * Copyright (c) 1990 The Regents of the University of California.
3*46104Sbostic  * All rights reserved.
4*46104Sbostic  *
5*46104Sbostic  * This code is derived from software contributed to Berkeley by
6*46104Sbostic  * Chris Torek.
7*46104Sbostic  *
8*46104Sbostic  * %sccs.include.redist.c%
921409Sdist  */
1021409Sdist 
1126660Sdonn #if defined(LIBC_SCCS) && !defined(lint)
12*46104Sbostic static char sccsid[] = "@(#)setbuf.c	5.3 (Berkeley) 01/20/91";
13*46104Sbostic #endif /* LIBC_SCCS and not lint */
1421409Sdist 
15*46104Sbostic #include <stdio.h>
16*46104Sbostic #include "local.h"
172032Swnj 
18*46104Sbostic void
19*46104Sbostic setbuf(fp, buf)
20*46104Sbostic 	FILE *fp;
21*46104Sbostic 	char *buf;
222032Swnj {
23*46104Sbostic 	(void) setvbuf(fp, buf, buf ? _IOFBF : _IONBF, BUFSIZ);
242032Swnj }
25