Namespaces
Variants
Views
Actions

std::setbuf

From cppreference.com
< cpp‎ | io‎ | c
Revision as of 23:01, 31 May 2013 by P12bot (Talk | contribs)

 
 
 
 
Defined in header <cstdio>
void setbuf( FILE* stream, char* buffer );

Sets the internal buffer to use for I/O operations performed on the C stream stream.

If buffer is not null, equivalent to std::setvbuf(stream, buffer, _IOFBF, BUFSIZ)

If buffer is null, equivalent to std::setvbuf(stream, NULL, _IONBF, 0), which turns off buffering.

Parameters

stream - the file stream to set the buffer to.
buffer - pointer to a buffer for the stream to use. If NULL is supplied, the buffering is turned off. If not null, must be able to hold at least BUFSIZ characters

Return value

(none)

See also

sets the buffer and its size for a file stream
(function) [edit]
C documentation for setbuf