X-Git-Url: https://pd.if.org/git/?p=pdclib;a=blobdiff_plain;f=functions%2Fstdio%2Fsetbuf.c;h=85137af39ff18a8ecf6bd602434c8e785a120aa9;hp=6d689b0f3f0fc2f8fdf66fb7cba894abfbd1a318;hb=0a5395faab237ba9008352b0f4bee9659bbd3d5f;hpb=34893ecc2200dc7017c36a54cb6c5f4c2378b5ec diff --git a/functions/stdio/setbuf.c b/functions/stdio/setbuf.c index 6d689b0..85137af 100644 --- a/functions/stdio/setbuf.c +++ b/functions/stdio/setbuf.c @@ -6,3 +6,19 @@ // ---------------------------------------------------------------------------- void setbuf( FILE * restrict stream, char * restrict buf ) { /* TODO */ }; + +/* PDPC code - unreviewed +{ + int ret; + + if (buf == NULL) + { + ret = setvbuf(stream, NULL, _IONBF, 0); + } + else + { + ret = setvbuf(stream, buf, _IOFBF, BUFSIZ); + } + return (ret); +} +*/