[fpc-pascal] FreePascal Windows - Force files to write to disk

Henry Vermaak henry.vermaak at gmail.com
Wed Mar 22 10:15:40 CET 2017


On Tue, Mar 21, 2017 at 06:01:17PM -0700, Ralf Quint wrote:
> On 3/21/2017 11:58 AM, James Richters wrote:
> >I have not tried FlushFileBuffers() yet, so I just tried it now,  I am getting the same results.
> Well, that is expected, as the issue has nothing to do with your program,
> it's the caching of the operating system that is responsible for the actual
> physical write to the disk.

No, FlushFileBuffers() flushes the OS cache - see the MSDN page.  The
problem here seems to be that the SSD has its own cache (in the FTL).

Henry



More information about the fpc-pascal mailing list