<<< 20.5.2009 15:54 - Jonas Maebe "" >>>
Roland Turcan wrote> I need to flush buffers from TFileStream which I should use function
> "fpfsync (Handle)", but as far as I found, there is no implementation
> of DO_SYSCALL for mac. DO_SYSCALL is implemented only for BSD.
JM> Why do you think that you need DO_SYSCALL?
I just didn't find relation of fpfsync function to mac os x implementation.
> When my application crashes all files modified over TFileStream are
> broken.
>
> How to force flushing file stream?
JM> uses
JM> unix;
JM> ...
JM> fpfsync(handle).
I have the same actually, but it doesn't work as I expect.
When I write into FileStream any data I call FlushBuffer function which contains fpfsync(handle), but because if still buggy version of ported application I have some expections which crashes application and then nearly all changed files are broken.
Are you sure, that fpfsync works fine on Mac OS?
JM> Jonas