According to the C Standard (7.21 Input/output )
SETBUF
which expands to an integer constant expression that is the size of
the buffer used by the setbuf function;
It is unspecified what is the type of the constant.
On the other hand the standard function setvbuf
can be used to specify a user-supplied buffer or the buffer allocated by the function. It has the following declaration
int setvbuf(FILE * restrict stream,
char * restrict buf,
int mode, size_t size);
where the parameter size
of the type size_t
specifies the size of the buffer.
As the size can not be a negative number then you may output its value as having the type size_t
.