fdatasync


SYNOPSIS
       #include <unistd.h>

       int fdatasync(int fildes);


DESCRIPTION
       The  fdatasync()  function  shall force all currently queued I/O opera-
       tions associated with the file indicated by file descriptor  fildes  to
       the synchronized I/O completion state.

       The  functionality  shall  be  equivalent  to  fsync()  with the symbol
       _POSIX_SYNCHRONIZED_IO defined, with the exception that all I/O  opera-
       tions shall be completed as defined for synchronized I/O data integrity
       completion.

RETURN VALUE
       If successful, the fdatasync() function shall return the value 0;  oth-
       erwise,  the  function shall return the value -1 and set errno to indi-
       cate the error. If the  fdatasync()  function  fails,  outstanding  I/O
       operations are not guaranteed to have been completed.

ERRORS
       The fdatasync() function shall fail if:

       EBADF  The  fildes  argument  is  not  a valid file descriptor open for
              writing.

       EINVAL This implementation does not support synchronized I/O  for  this
              file.


       In  the  event  that any of the queued I/O operations fail, fdatasync()
       shall return the error conditions defined for read() and write().

       The following sections are informative.

EXAMPLES
       None.

APPLICATION USAGE
       None.

RATIONALE
       None.

FUTURE DIRECTIONS
       None.

SEE ALSO
       aio_fsync() , fcntl() , fsync() , open() , read() , write() , the  Base
       Definitions volume of IEEE Std 1003.1-2001, <unistd.h>


IEEE/The Open Group                  2003                         FDATASYNC(P)
Man Pages Copyright Respective Owners. Site Copyright (C) 1994 - 2013 Hurricane Electric. All Rights Reserved.