virtual int overflow(int c = EOF);
If c != EOF, the protected virtual member function endeavors to insert the element (char)c into the output buffer. It
can do so in various ways:
- If a write position is available, it can store the element into the write position and increment the next pointer for
the output buffer.
- If the stored strstreambuf mode says the controlled sequence is modifiable, extendable, and not frozen, the
function can make a write position available by allocating new for the output buffer. (Extending the output buffer
this way also extends any associated input buffer.)
If the function cannot succeed, it returns EOF. Otherwise, if c == EOF it returns some value other than EOF. Otherwise,
it returns c.