C Standard Library

C <stdio.h> - BUFSIZ constant



The C <stdio.h> BUFSIZ is a macro constant that expands to an integral expression with the size of the buffer used by the setbuf() function.

In the <stdio.h> header file, it is defined as follows:

#define BUFSIZ /* implementation defined */             

Example:

The example below shows the value of BUFSIZ constant in a given implementation.

#include <stdio.h>
 
int main (){

  //displaying the value of BUFSIZ
  printf("BUFSIZ = %d\n", BUFSIZ);
 
  return 0;
}

The output of the above code will be:

BUFSIZ = 8192

❮ C <stdio.h> Library