cpp/io/basic filebuf/sync

If a put area exists (e.g. the file was opened for writing), calls overflow to write all pending output to the file, then flushes the file as if by calling std.

If a get area exists (e.g. the file was opened for reading), the effect is implementation-defined. Typical implementation may empty out the get area and move the current file position back by the corresponding number of bytes.

Parameters
(none)

Return value
in case of success, in case of failure.