
std::fflush does not guarantee that file buffers are flushed to the disk. Use _commit on Windows and fsync on all other OSes to ensure that the file is flushed to the disk.
std::fflush does not guarantee that file buffers are flushed to the disk. Use _commit on Windows and fsync on all other OSes to ensure that the file is flushed to the disk.