Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

fcntl(2)

open(2)

read(2)

write(2)

fsync(3C)

aio_fsync(3R)

fcntl(5)

fdatasync(3R)

NAME

fdatasync − synchronize a file’s data

SYNOPSIS

cc [ flag ... ] file ... −lposix4 [ library ... ]

#include <unistd.h>

int fdatasync(int fildes);

MT-LEVEL

Async-Signal-Safe

DESCRIPTION

fdatasync() forces all currently queued I/O operations associated with the file descriptor fildes to synchronized I/O data integrity completion.  See fcntl(5) definition of O_DSYNC. 

RETURN VALUES

fdatasync() returns 0 upon success; otherwise, it returns -1 and sets errno to indicate the error condition. 

ERRORS

EBADF fildes is not a valid file descriptor. 

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

ENOSYS fdatasync() is not supported by this implementation. 

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

SEE ALSO

fcntl(2), open(2), read(2), write(2), fsync(3C), aio_fsync(3R), fcntl(5)

NOTES

If fdatasync() fails, outstanding I/O operations are not guaranteed to have been completed. 

SunOS 5.5/SPARC  —  Last change: 19 Aug 1993

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026