[#BloombergLP-bdls-FdStreamBuf-setbuf]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdls.adoc[bdls]::xref:BloombergLP/bdls/FdStreamBuf.adoc[FdStreamBuf]::setbuf
:relfileprefix: ../../../
:mrdocs:

Use the specified `buffer` of the specified `numBytes` capacity as the input&sol;output buffer for this `streambuf`&period; If `buffer &equals;&equals; 0`, the buffer is dynamically allocated with a default size&period; If both `buffer` and `numBytes` are zero a 1&hyphen;byte buffer is dynamically allocated&period; The behavior is undefined if any I&sol;O has preceded this call, and unless the buffer is uninitialized before this call&period;

== Synopsis

Declared in `&lt;bdls&lowbar;fdstreambuf&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
virtual
xref:BloombergLP/bdls/FdStreamBuf.adoc[FdStreamBuf]*
setbuf(
    char&lowbar;type* buffer,
    std::streamsize numBytes) override;
----


[.small]#Created with https://www.mrdocs.com[MrDocs]#
