flock(3S)
flock: flockfile, ftrylockfile, funlockfile --
standard I/O synchronization functions
Synopsis
#include <stdio.h>
void flockfile(FILE file);
void funlockfile(FILE file);
int ftrylockfile(FILE file);
Description
These functions provide for explicit application-level
locking of standard I/O stream objects.
They are used by a thread to delineate a sequence of I/O statements
that are to be executed as a unit.
flockfile-
grants thread ownership of a file, suspends thread until
ownership is granted
ftrylockfile-
similar to flockfile, except that it returns
a value for success or failure
funlockfile-
relinquishes file ownership granted to a thread by a previous successful
call to flockfile or ftrylockfile
References
flockfile(3S),
ftrylockfile(3S),
funlockfile(3S),
Intro(3S)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004