Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ setpgid(2) — svr3 — mips UMIPS RISC/os 5.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

setpgrp(2)

ioctl(2)



SETPGID(2-SVR3)     RISC/os Reference Manual      SETPGID(2-SVR3)



NAME
     setpgid - set process group ID for job control

SYNOPSIS
          #include <sys/types.h>

          int setpgid (pid, pgid)
          int pid,pgid;

DESCRIPTION
     The setpgid() function is used to either join an existing
     process group or create a new process group within the ses-
     sion of the calling process.  The process group ID of a ses-
     sion leader shall not change.  Upon successful completion,
     the process group ID of the process with a process ID that
     matches pid shall be set to pgid.  As a special, if pid is
     zero, the process ID of the calling process shall be used.
     Also, if pgid is zero, the process ID of the indicated pro-
     cess shall be used.

RETURNS
     Upon successful completion, the setpgid() function returns a
     value of zero.  Otherwise, a value of -1 is returned and
     errno is set to indicate the error.

ERRORS
     If any of the following conditions occur, the setpgid()
     function shall return -1 and set errno to the corresponding
     value:

     [EINVAL]       The value of the pgid argument is less than
                    or equal to zero or is not a value supported
                    by the implementation.

     [EPERM]        The process indicated by the pid argument is
                    a session leader.

                    The value of the pid argument matches the
                    process ID of a child process of the calling
                    process and the child process is not in the
                    same session as the calling process.
                    The value of the pgid argument does not match
                    the process ID of the process indicated by
                    the pid argument and there is no process with
                    a process group ID that matches the value of
                    the pgid argument in the same session as the
                    calling process.

     [ESRCH]        The value of the pid argument does not match
                    the process ID of the calling process or of a
                    child process of the calling process.




                        Printed 11/19/92                   Page 1





SETPGID(2-SVR3)     RISC/os Reference Manual      SETPGID(2-SVR3)



SEE ALSO
     setpgrp(2), ioctl(2)





















































 Page 2                 Printed 11/19/92



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026