about summary refs log tree commit diff
path: root/src/stdio/setbuf.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stdio/setbuf.c')
-rw-r--r--src/stdio/setbuf.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/stdio/setbuf.c b/src/stdio/setbuf.c
new file mode 100644
index 00000000..205afcfe
--- /dev/null
+++ b/src/stdio/setbuf.c
@@ -0,0 +1,6 @@
+#include "stdio_impl.h"
+
+void setbuf(FILE *f, char *buf)
+{
+	setvbuf(f, buf, buf ? _IOFBF : _IONBF, BUFSIZ);
+}