Print this page
4330 open(2) manual describes O_SYNC twice

Split Close
Expand all
Collapse all
          --- old/usr/src/man/man2/open.2
          +++ new/usr/src/man/man2/open.2
↓ open down ↓ 2 lines elided ↑ open up ↑
   3    3  .\" Copyright 1989 AT&T
   4    4  .\" Portions Copyright (c) 1992, X/Open Company Limited.  All Rights Reserved.
   5    5  .\" Portions Copyright (c) 2013, OmniTI Computer Consulting, Inc.  All Rights Reserved.
   6    6  .\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for permission to reproduce portions of its copyrighted documentation. Original documentation from The Open Group can be obtained online at
   7    7  .\" http://www.opengroup.org/bookstore/.
   8    8  .\" The Institute of Electrical and Electronics Engineers and The Open Group, have given us permission to reprint portions of their documentation. In the following statement, the phrase "this text" refers to portions of the system documentation. Portions of this text are reprinted and reproduced in electronic form in the Sun OS Reference Manual, from IEEE Std 1003.1, 2004 Edition, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 6, Copyright (C) 2001-2004 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between these versions and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html.
   9    9  .\"  This notice shall appear on any product containing this material.
  10   10  .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
  11   11  .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
  12   12  .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
  13      -.TH OPEN 2 "Jun 16, 2008"
       13 +.TH OPEN 2 "Nov 16, 2013"
  14   14  .SH NAME
  15   15  open, openat \- open a file
  16   16  .SH SYNOPSIS
  17   17  .LP
  18   18  .nf
  19   19  #include <sys/types.h>
  20   20  #include <sys/stat.h>
  21   21  #include <fcntl.h>
  22   22  
  23   23  \fBint\fR \fBopen\fR(\fBconst char *\fR\fIpath\fR, \fBint\fR \fIoflag\fR, \fB/* mode_t\fR \fImode\fR */);
↓ open down ↓ 101 lines elided ↑ open up ↑
 125  125  bit is set in the directory in which the file is being created, the file's
 126  126  group \fBID\fR is set to the group \fBID\fR of its parent directory.  If the
 127  127  group \fBID\fR of the new file does not match the effective group \fBID\fR or
 128  128  one of the supplementary groups IDs, the \fBS_ISGID\fR bit is cleared. The
 129  129  access permission bits (see \fB<sys/stat.h>\fR) of the file mode are set to the
 130  130  value of \fImode\fR, modified as follows (see \fBcreat\fR(2)): a bitwise-AND is
 131  131  performed on the file-mode bits and the corresponding bits in the complement of
 132  132  the process's file mode creation mask. Thus, all bits set in the process's file
 133  133  mode creation mask (see \fBumask\fR(2)) are correspondingly cleared in the
 134  134  file's permission mask. The "save text image after execution bit" of the mode
 135      -is cleared (see \fBchmod\fR(2)). \fBO_SYNC\fR Write I/O operations on the file
 136      -descriptor complete as defined by synchronized I/O file integrity completion
 137      -(see \fBfcntl.h\fR(3HEAD) definition of \fBO_SYNC\fR.) When bits other than the
 138      -file permission bits are set, the effect is unspecified. The \fImode\fR
 139      -argument does not affect whether the file is open for reading, writing or for
 140      -both.
      135 +is cleared (see \fBchmod\fR(2)). When bits other than the file permission bits
      136 +are set, the effect is unspecified. The \fImode\fR argument does not affect
      137 +whether the file is open for reading, writing or for both.
 141  138  .RE
 142  139  
 143  140  .sp
 144  141  .ne 2
 145  142  .na
 146  143  \fB\fBO_DSYNC\fR\fR
 147  144  .ad
 148  145  .sp .6
 149  146  .RS 4n
 150  147  Write I/O operations on the file descriptor complete as defined by synchronized
↓ open down ↓ 146 lines elided ↑ open up ↑
 297  294  .RE
 298  295  
 299  296  .sp
 300  297  .ne 2
 301  298  .na
 302  299  \fB\fBO_SYNC\fR\fR
 303  300  .ad
 304  301  .sp .6
 305  302  .RS 4n
 306  303  Write I/O operations on the file descriptor complete as defined by synchronized
 307      -I/O file integrity completion.
      304 +I/O file integrity completion (see \fBfcntl.h\fR(3HEAD) definition of
      305 +\fBO_SYNC\fR.)
 308  306  .RE
 309  307  
 310  308  .sp
 311  309  .ne 2
 312  310  .na
 313  311  \fB\fBO_TRUNC\fR\fR
 314  312  .ad
 315  313  .sp .6
 316  314  .RS 4n
 317  315  If the file exists and is a regular file, and the file is successfully opened
↓ open down ↓ 604 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX