2 Copyright © 2004, The AROS Development Team. All rights reserved.
5 POSIX function fsync().
8 #include <exec/types.h>
9 #include <dos/dosextens.h>
10 #include <proto/exec.h>
11 #include <proto/dos.h>
19 /* FIXME: documentation */
24 fdesc
*fdesc
= __getfdesc(fd
);
26 if (!fdesc
|| !(fdesc
->flags
& O_WRITE
))
32 if (!Flush((BPTR
) fdesc
->fh
))
34 errno
= IoErr2errno(IoErr());