Line | |
---|
1 | .\" Copyright (c) 1980 Regents of the University of California.
|
---|
2 | .\" All rights reserved. The Berkeley software License Agreement
|
---|
3 | .\" specifies the terms and conditions for redistribution.
|
---|
4 | .\"
|
---|
5 | .\" @(#)getpid.2 6.3 (Berkeley) 5/13/86
|
---|
6 | .\"
|
---|
7 | .TH GETPID 2 "May 13, 1986"
|
---|
8 | .UC 4
|
---|
9 | .SH NAME
|
---|
10 | getpid, getppid \- get process identification
|
---|
11 | .SH SYNOPSIS
|
---|
12 | .ft B
|
---|
13 | .nf
|
---|
14 | #include <sys/types.h>
|
---|
15 | #include <unistd.h>
|
---|
16 |
|
---|
17 | pid_t getpid(void)
|
---|
18 | pid_t getppid(void)
|
---|
19 | .fi
|
---|
20 | .ft R
|
---|
21 | .SH DESCRIPTION
|
---|
22 | .B Getpid
|
---|
23 | returns
|
---|
24 | the process ID of
|
---|
25 | the current process.
|
---|
26 | Most often it is used
|
---|
27 | to generate uniquely-named temporary files.
|
---|
28 | .PP
|
---|
29 | .B Getppid
|
---|
30 | returns the process ID of the parent
|
---|
31 | of the current process.
|
---|
32 | .SH "SEE ALSO
|
---|
33 | .BR fork (2).
|
---|
Note:
See
TracBrowser
for help on using the repository browser.