0 Successful completion. -1 Indicates an error. The function sets errno to one of the following values: o EACCES - The value of the pid argument matches the process ID of a child process of the calling process and the child process has successfully executed one of the exec functions. o EINVAL - The value of the pgid argument is less than 0, or is not a value supported by the implementation. o 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 is valid but 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. o 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.