1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114
|
.\" Copyright 1997 Nicolas Lichtmaier <nick@debian.org>
.\" Created Thu Aug 7 00:44:00 ART 1997
.\"
.\" This is free documentation; you can redistribute it and/or
.\" modify it under the terms of the GNU General Public License as
.\" published by the Free Software Foundation; either version 2 of
.\" the License, or (at your option) any later version.
.\"
.\" The GNU General Public License's references to "object code"
.\" and "executables" are to be interpreted as the output of any
.\" document formatting or typesetting system, including
.\" intermediate and printed output.
.\"
.\" This manual is distributed in the hope that it will be useful,
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
.\" GNU General Public License for more details.
.\"
.\" Japanese Version Copyright (c) 2000 Yuichi SATO
.\" all rights reserved.
.\" Translated Tue Jul 11 19:02:58 JST 2000
.\" by Yuichi SATO <sato@complex.eng.hokudai.ac.jp>
.\"
.\"WORD: apply Ŭ
.\"WORD: remove
.\"WORD: exclusive ¾
.\"WORD: descriptor ǥץ
.\"WORD:
.\"
.TH LOCKF 3 "6 August 1997" "Linux 2.0" "Linux Programmer's Manual"
.SH ̾
lockf \- ƤեФ POSIX åŬѡƥȡ롣
.SH
.B #include <sys/file.h>
.sp
.BR "int lockf(int " fd ", int " cmd ", off_t " len );
.SH
ƤեФơPOSIX åŬѡƥȡ롣
ե
.I fd
ǻꤵ롣
δؿñ
.BR fcntl "(2)"
ؤΥեǤ롣
ͭʥץʲ˵롣
.RS
.sp
.TP 1.0i
.B F_LOCK
ե¾åꤹ롣
ǡեФơ
ĤΥץ¾åݻ뤳ȤǤ롣
ե뤬˥åƤ硢
Υåޤǥ֥å롣
.TP
.B F_TLOCK
.B F_LOCK
ƱͤǤ뤬ե뤬˥åƤ硢
֥å˥顼֤
.TP
.B F_ULOCK
եΥå롣
.TP
.B F_TEST
Τ褦˥åΥƥȤ롣
.I fd
åƤʤΥץˤåƤ硢0 ֤
¾ΥץåݻƤ硢\-1 ֤
.I errno
.BR EACCES
ꤹ롣
.sp
.RE
.SH ֤
硢0 ֤롣
顼ξ硢\-1 ֤졢
.I errno
顼бͤꤵ롣
.SH 顼
.TP
.B EAGAIN
ե뤬åơ
.B LOCK_NB
ե饰Ƥ롣
ޤϡե뤬¾ΥץˤޥåפƤ뤿ˡ
ػߤƤ롣
.TP
.B EBADF
.I fd
ƤեΥǥץǤϤʤ
.TP
.B EDEADLK
ꤵ줿åǥåɥåƤ롣
.TP
.B EINVAL
.I fd
̵ꤵ줿
.TP
.B ENOLCK
¿Υȥå졢åơ֥뤬줿
.SH
SYSV
.SH Ϣ
.BR fcntl (2),
.BR flock (2)
.br
.IR /usr/src/linux/Documentation
ˤ
.I locks.txt
.I mandatory.txt
⻲Ȥ뤳ȡ
|