1c4dd129bSPeter Avalos.\" Copyright (c) 2008 Ed Schouten <ed@FreeBSD.org> 2c4dd129bSPeter Avalos.\" All rights reserved. 3c4dd129bSPeter Avalos.\" 4c4dd129bSPeter Avalos.\" Redistribution and use in source and binary forms, with or without 5c4dd129bSPeter Avalos.\" modification, are permitted provided that the following conditions 6c4dd129bSPeter Avalos.\" are met: 7c4dd129bSPeter Avalos.\" 1. Redistributions of source code must retain the above copyright 8c4dd129bSPeter Avalos.\" notice, this list of conditions and the following disclaimer. 9c4dd129bSPeter Avalos.\" 2. Redistributions in binary form must reproduce the above copyright 10c4dd129bSPeter Avalos.\" notice, this list of conditions and the following disclaimer in the 11c4dd129bSPeter Avalos.\" documentation and/or other materials provided with the distribution. 12c4dd129bSPeter Avalos.\" 13c4dd129bSPeter Avalos.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 14c4dd129bSPeter Avalos.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15c4dd129bSPeter Avalos.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 16c4dd129bSPeter Avalos.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 17c4dd129bSPeter Avalos.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18c4dd129bSPeter Avalos.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19c4dd129bSPeter Avalos.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20c4dd129bSPeter Avalos.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21c4dd129bSPeter Avalos.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22c4dd129bSPeter Avalos.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23c4dd129bSPeter Avalos.\" SUCH DAMAGE. 24c4dd129bSPeter Avalos.\" 25c4dd129bSPeter Avalos.\" Portions of this text are reprinted and reproduced in electronic form 26c4dd129bSPeter Avalos.\" from IEEE Std 1003.1, 2004 Edition, Standard for Information Technology -- 27c4dd129bSPeter Avalos.\" Portable Operating System Interface (POSIX), The Open Group Base 28c4dd129bSPeter Avalos.\" Specifications Issue 6, Copyright (C) 2001-2004 by the Institute of 29c4dd129bSPeter Avalos.\" Electrical and Electronics Engineers, Inc and The Open Group. In the 30c4dd129bSPeter Avalos.\" event of any discrepancy between this version and the original IEEE and 31c4dd129bSPeter Avalos.\" The Open Group Standard, the original IEEE and The Open Group Standard is 32c4dd129bSPeter Avalos.\" the referee document. The original Standard can be obtained online at 33c4dd129bSPeter Avalos.\" http://www.opengroup.org/unix/online.html. 34c4dd129bSPeter Avalos.\" 35c4dd129bSPeter Avalos.\" $FreeBSD: src/lib/libc/gen/posix_spawnattr_getflags.3,v 1.1 2008/07/28 02:22:19 davidxu Exp $ 36c4dd129bSPeter Avalos.\" 37ee79eb2cSSascha Wildner.Dd April 7, 2009 38c4dd129bSPeter Avalos.Dt POSIX_SPAWNATTR_GETFLAGS 3 39c4dd129bSPeter Avalos.Os 40c4dd129bSPeter Avalos.Sh NAME 41c4dd129bSPeter Avalos.Nm posix_spawnattr_getflags , 42c4dd129bSPeter Avalos.Nm posix_spawnattr_setflags 43c4dd129bSPeter Avalos.Nd "get and set the spawn-flags attribute of a spawn attributes object" 44c4dd129bSPeter Avalos.Sh LIBRARY 45c4dd129bSPeter Avalos.Lb libc 46c4dd129bSPeter Avalos.Sh SYNOPSIS 47c4dd129bSPeter Avalos.In spawn.h 48c4dd129bSPeter Avalos.Ft int 49c4dd129bSPeter Avalos.Fn posix_spawnattr_getflags "const posix_spawnattr_t *restrict attr" "short *restrict flags" 50c4dd129bSPeter Avalos.Ft int 51c4dd129bSPeter Avalos.Fn posix_spawnattr_setflags "posix_spawnattr_t *attr" "short flags" 52c4dd129bSPeter Avalos.Sh DESCRIPTION 53c4dd129bSPeter AvalosThe 54c4dd129bSPeter Avalos.Fn posix_spawnattr_getflags 55c4dd129bSPeter Avalosfunction obtains the value of the spawn-flags attribute from the 56c4dd129bSPeter Avalosattributes object referenced by 57c4dd129bSPeter Avalos.Fa attr . 58c4dd129bSPeter Avalos.Pp 59c4dd129bSPeter AvalosThe 60c4dd129bSPeter Avalos.Fn posix_spawnattr_setflags 61c4dd129bSPeter Avalosfunction sets the spawn-flags attribute in an initialized 62c4dd129bSPeter Avalosattributes object referenced by 63c4dd129bSPeter Avalos.Fa attr . 64c4dd129bSPeter Avalos.Pp 65c4dd129bSPeter AvalosThe spawn-flags attribute is used to indicate which process attributes 66c4dd129bSPeter Avalosare to be changed in the new process image when invoking 67c4dd129bSPeter Avalos.Fn posix_spawn 68c4dd129bSPeter Avalosor 69c4dd129bSPeter Avalos.Fn posix_spawnp . 70c4dd129bSPeter AvalosIt is the bitwise-inclusive OR of zero or more of the following flags 71c4dd129bSPeter Avalos(see 72c4dd129bSPeter Avalos.Fn posix_spawn ) : 73783d47c4SSascha Wildner.Bl -tag -offset indent -width ".Dv POSIX_SPAWN_SETSCHEDPARAM" 74c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_RESETIDS 75c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_SETPGROUP 76c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_SETSIGDEF 77c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_SETSIGMASK 78c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_SETSCHEDPARAM 79c4dd129bSPeter Avalos.It Dv POSIX_SPAWN_SETSCHEDULER 80c4dd129bSPeter Avalos.El 81c4dd129bSPeter Avalos.Pp 82c4dd129bSPeter AvalosThese flags are defined in 83c4dd129bSPeter Avalos.In spawn.h . 84c4dd129bSPeter AvalosThe default value of this attribute is as if no flags were set. 85c4dd129bSPeter Avalos.Sh RETURN VALUES 86c4dd129bSPeter AvalosThe 87c4dd129bSPeter Avalos.Fn posix_spawnattr_getflags 88c4dd129bSPeter Avalosand 89c4dd129bSPeter Avalos.Fn posix_spawnattr_setflags 90c4dd129bSPeter Avalosfunctions return zero. 91c4dd129bSPeter Avalos.Sh SEE ALSO 92c4dd129bSPeter Avalos.Xr posix_spawn 3 , 93c4dd129bSPeter Avalos.Xr posix_spawnattr_destroy 3 , 94c4dd129bSPeter Avalos.Xr posix_spawnattr_init 3 , 95c4dd129bSPeter Avalos.Xr posix_spawnp 3 96c4dd129bSPeter Avalos.Sh STANDARDS 97c4dd129bSPeter AvalosThe 98c4dd129bSPeter Avalos.Fn posix_spawnattr_getflags 99c4dd129bSPeter Avalosand 100c4dd129bSPeter Avalos.Fn posix_spawnattr_setflags 101c4dd129bSPeter Avalosfunctions conform to 102c4dd129bSPeter Avalos.St -p1003.1-2001 . 103c4dd129bSPeter Avalos.Sh HISTORY 104c4dd129bSPeter AvalosThe 105c4dd129bSPeter Avalos.Fn posix_spawnattr_getflags 106c4dd129bSPeter Avalosand 107c4dd129bSPeter Avalos.Fn posix_spawnattr_setflags 108c4dd129bSPeter Avalosfunctions first appeared in 109c4dd129bSPeter Avalos.Fx 8.0 . 110c4dd129bSPeter Avalos.Sh AUTHORS 111*c9c6988bSSascha Wildner.An \&Ed Schouten Aq Mt ed@FreeBSD.org 112