9103 opengroup acknowledgement should be properly formatted in man pages
[unleashed.git] / usr / src / man / man3c / posix_spawnattr_destroy.3c
blobf430e366f6962b11d5ea8f63290718d96c5727d6
1 .\"
2 .\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for
3 .\" permission to reproduce portions of its copyrighted documentation.
4 .\" Original documentation from The Open Group can be obtained online at
5 .\" http://www.opengroup.org/bookstore/.
6 .\"
7 .\" The Institute of Electrical and Electronics Engineers and The Open
8 .\" Group, have given us permission to reprint portions of their
9 .\" documentation.
10 .\"
11 .\" In the following statement, the phrase ``this text'' refers to portions
12 .\" of the system documentation.
13 .\"
14 .\" Portions of this text are reprinted and reproduced in electronic form
15 .\" in the SunOS Reference Manual, from IEEE Std 1003.1, 2004 Edition,
16 .\" Standard for Information Technology -- Portable Operating System
17 .\" Interface (POSIX), The Open Group Base Specifications Issue 6,
18 .\" Copyright (C) 2001-2004 by the Institute of Electrical and Electronics
19 .\" Engineers, Inc and The Open Group.  In the event of any discrepancy
20 .\" between these versions and the original IEEE and The Open Group
21 .\" Standard, the original IEEE and The Open Group Standard is the referee
22 .\" document.  The original Standard can be obtained online at
23 .\" http://www.opengroup.org/unix/online.html.
24 .\"
25 .\" This notice shall appear on any product containing this material.
26 .\"
27 .\" The contents of this file are subject to the terms of the
28 .\" Common Development and Distribution License (the "License").
29 .\" You may not use this file except in compliance with the License.
30 .\"
31 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
32 .\" or http://www.opensolaris.org/os/licensing.
33 .\" See the License for the specific language governing permissions
34 .\" and limitations under the License.
35 .\"
36 .\" When distributing Covered Code, include this CDDL HEADER in each
37 .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
38 .\" If applicable, add the following below this CDDL HEADER, with the
39 .\" fields enclosed by brackets "[]" replaced with your own identifying
40 .\" information: Portions Copyright [yyyy] [name of copyright owner]
41 .\"
42 .\"
43 .\" Copyright (c) 2001, The IEEE and The Open Group.  All Rights Reserved.
44 .\" Portions Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved.
45 .\"
46 .TH POSIX_SPAWNATTR_DESTROY 3C "Jan 30, 2004"
47 .SH NAME
48 posix_spawnattr_destroy, posix_spawnattr_init \- destroy and initialize spawn
49 attributes object
50 .SH SYNOPSIS
51 .LP
52 .nf
53 #include <spawn.h>
55 \fBint\fR \fBposix_spawnattr_destroy\fR(\fBposix_spawnattr_t *\fR\fIattr\fR);
56 .fi
58 .LP
59 .nf
60 \fBint\fR \fBposix_spawnattr_init\fR(\fBposix_spawnattr_t *\fR\fIattr\fR);
61 .fi
63 .SH DESCRIPTION
64 .sp
65 .LP
66 The \fBposix_spawnattr_destroy()\fR function destroys a spawn attributes
67 object. A destroyed \fIattr\fR attributes object can be reinitialized using
68 \fBposix_spawnattr_init()\fR. The results of otherwise referencing the object
69 after it has been destroyed are undefined. An implementation can cause
70 \fBposix_spawnattr_destroy()\fR to set the object referenced by \fIattr\fR to
71 an invalid value.
72 .sp
73 .LP
74 The \fBposix_spawnattr_init()\fR function initializes a spawn attributes object
75 \fIattr\fR with the default value for all of the individual attributes used by
76 the implementation. Results are undefined if \fBposix_spawnattr_init()\fR is
77 called specifying an already initialized \fIattr\fR attributes object.
78 .sp
79 .LP
80 A spawn attributes object is of type \fBposix_spawnattr_t\fR (defined in
81 <\fBspawn.h\fR>) and is used to specify the inheritance of process attributes
82 across a spawn operation.
83 .sp
84 .LP
85 No attributes other than those defined by IEEE Std 1003.1-200x are provided.
86 .sp
87 .LP
88 The resulting spawn attributes object (possibly modified by setting individual
89 attribute values), is used to modify the behavior of \fBposix_spawn\fR(3C) or
90 \fBposix_spawnp\fR(3C). After a spawn attributes object has been used to spawn
91 a process by a call to \fBposix_spawn()\fR or \fBposix_spawnp()\fR, any
92 function affecting the attributes object (including destruction) will not
93 affect any process that has been spawned in this way.
94 .SH RETURN VALUES
95 .sp
96 .LP
97 Upon successful completion, \fBposix_spawnattr_destroy()\fR and
98 \fBposix_spawnattr_init()\fR return 0. Otherwise, an error number is returned
99 to indicate the error.
100 .SH ERRORS
103 The \fBposix_spawnattr_init()\fR function will fail if:
105 .ne 2
107 \fB\fBENOMEM\fR\fR
109 .RS 10n
110 Insufficient memory exists to initialize the spawn attributes object.
115 The \fBposix_spawnattr_destroy()\fR function may fail if:
117 .ne 2
119 \fB\fBEINVAL\fR\fR
121 .RS 10n
122 The value specified by \fIattr\fR is invalid.
125 .SH ATTRIBUTES
128 See \fBattributes\fR(5) for descriptions of the following attributes:
133 box;
134 c | c
135 l | l .
136 ATTRIBUTE TYPE  ATTRIBUTE VALUE
138 Interface Stability     Standard
140 MT-Level        MT-Safe
143 .SH SEE ALSO
146 \fBposix_spawn\fR(3C), \fBposix_spawnattr_getflags\fR(3C),
147 \fBposix_spawnattr_getpgroup\fR(3C), \fBposix_spawnattr_getschedparam\fR(3C),
148 \fBposix_spawnattr_getschedpolicy\fR(3C),
149 \fBposix_spawnattr_getsigdefault\fR(3C), \fBposix_spawnattr_getsigmask\fR(3C),
150 \fBattributes\fR(5), \fBstandards\fR(5)