setsid.2

来自「Unix操作系统minix 2.0源码」· 2 代码 · 共 38 行

2
38
字号
.TH SETSID 2.SH NAMEsetsid, getpgrp \- create process group, get process group id.SH SYNOPSIS.ft B.nf#include <sys/types.h>#include <unistd.h>pid_t setsid(void)pid_t getpgrp(void).fi.ft P.SH DESCRIPTION.B Setsid()creates a new session if the calling process is not already a sessionleader.  The calling process becomes the session leader of a new processgroup and the process group ID of this new process group will be equal tothe process ID of the new session leader.  The process group ID is inheritedon a.BR fork() ..PP.B Getpgrp()returns the process group ID of the calling process..SH "SEE ALSO".BR kill (2),.BR termios (3),.BR tty (4)..SH DIAGNOSTICS.B Setsid()returns the new process group ID on success, or \-1 with.B errnoset to.B EPERMif the process is already a session leader..SH AUTHORKees J. Bot (kjb@cs.vu.nl)

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?