From owner-freebsd-doc Mon Nov 27 11:12:23 2000 Delivered-To: freebsd-doc@freebsd.org Received: from fw.wintelcom.net (ns1.wintelcom.net [209.1.153.20]) by hub.freebsd.org (Postfix) with ESMTP id 5E2BD37B479; Mon, 27 Nov 2000 11:12:20 -0800 (PST) Received: (from bright@localhost) by fw.wintelcom.net (8.10.0/8.10.0) id eARJCKg08915; Mon, 27 Nov 2000 11:12:20 -0800 (PST) Date: Mon, 27 Nov 2000 11:12:20 -0800 From: Alfred Perlstein To: Kris Kennaway Cc: doc@FreeBSD.org Subject: Re: cvs commit: src/usr.sbin/inetd builtins.c Message-ID: <20001127111219.J8051@fw.wintelcom.net> References: <200011270405.eAR45H578642@green.dyndns.org> <200011270450.eAR4oG579042@green.dyndns.org> <200011271508.KAA94135@khavrinen.lcs.mit.edu> <20001127103736.H8051@fw.wintelcom.net> <20001127104326.B62924@citusc17.usc.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20001127104326.B62924@citusc17.usc.edu>; from kris@FreeBSD.org on Mon, Nov 27, 2000 at 10:43:26AM -0800 Sender: owner-freebsd-doc@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org * Kris Kennaway [001127 10:42] wrote: > On Mon, Nov 27, 2000 at 10:37:36AM -0800, Alfred Perlstein wrote: > > > On a side note, why isn't O_NOFOLLOW(sp?) not documented in open(2). > > Are there any other flags not documented and if possible can I get > > a short and concise summary of them so that I can update the manpage? > > Read the header. I think I actually have an uncommitted patch here > which fixes the docs. Anyone want to make any suggestions before I commit this? Index: open.2 =================================================================== RCS file: /home/ncvs/src/lib/libc/sys/open.2,v retrieving revision 1.13 diff -u -u -r1.13 open.2 --- open.2 2000/04/21 09:41:54 1.13 +++ open.2 2000/11/27 19:16:30 @@ -83,6 +83,9 @@ O_EXCL error if create and file exists O_SHLOCK atomically obtain a shared lock O_EXLOCK atomically obtain an exclusive lock +O_ASYNC signal process group when data ready +O_FSYNC synchronous writes +O_NOFOLLOW do not follow symlinks .Ed .Pp Opening a file with @@ -120,6 +123,25 @@ The first time the process attempts to perform I/O on the open file it will block (not currently implemented). .Pp +Opening a file with +.Dv O_ASYNC +will cause the process group to recieve a SIGIO signal when data +becomes available on the descriptor. +If +.Dv O_FSYNC +is used in the mask, all writes will +immediately be written to disk, +the kernel will not cache written data +and all writes on the descriptor will not return until +the data to be written completes. +If +.Dv O_NOFOLLOW +is used in the mask and the target file passed to +.Fn open +is a symbolic link then the +.Fn open +will fail. +.Pp When opening a file, a lock with .Xr flock 2 semantics can be obtained by setting @@ -216,6 +238,9 @@ The process has already reached its limit for open file descriptors. .It Bq Er ENFILE The system file table is full. +.It Bq Er EMLINK +.Dv O_NOFOLLOW +was specified and the target is a symbolic link. .It Bq Er ENXIO The named file is a character special or block special file, and the device associated with this special file -- -Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org] "I have the heart of a child; I keep it in a jar on my desk." To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-doc" in the body of the message