- Correct macro usage;

- sort section order.

From Bug Hunting.
This commit is contained in:
abs 2012-11-22 16:19:49 +00:00
parent d875702485
commit 2a29d4b2b4

View File

@ -1,4 +1,4 @@
.\" $NetBSD: exec.3,v 1.21 2010/03/22 19:30:53 joerg Exp $ .\" $NetBSD: exec.3,v 1.22 2012/11/22 16:19:49 abs Exp $
.\" .\"
.\" Copyright (c) 1991, 1993 .\" Copyright (c) 1991, 1993
.\" The Regents of the University of California. All rights reserved. .\" The Regents of the University of California. All rights reserved.
@ -59,7 +59,7 @@
.Fn execvp "const char *file" "char *const argv[]" .Fn execvp "const char *file" "char *const argv[]"
.Sh DESCRIPTION .Sh DESCRIPTION
The The
.Nm exec .Fn exec
family of functions replaces the current process image with a family of functions replaces the current process image with a
new process image. new process image.
The functions described in this manual page are front-ends for the function The functions described in this manual page are front-ends for the function
@ -185,7 +185,7 @@ executes a file with the program tracing facilities enabled (see
.Xr ptrace 2 ) . .Xr ptrace 2 ) .
.Sh RETURN VALUES .Sh RETURN VALUES
If any of the If any of the
.Nm exec .Fn exec
functions returns, an error will have occurred. functions returns, an error will have occurred.
The return value is \-1, and the global variable The return value is \-1, and the global variable
.Va errno .Va errno
@ -195,33 +195,6 @@ will be set to indicate the error.
.It Pa /bin/sh .It Pa /bin/sh
The shell. The shell.
.El .El
.Sh ERRORS
.Fn execl ,
.Fn execle ,
.Fn execlp
and
.Fn execvp
may fail and set
.Va errno
for any of the errors specified for the library functions
.Xr execve 2
and
.Xr malloc 3 .
.Pp
.Fn exect
and
.Fn execv
may fail and set
.Va errno
for any of the errors specified for the library function
.Xr execve 2 .
.Sh SEE ALSO
.Xr sh 1 ,
.Xr execve 2 ,
.Xr fork 2 ,
.Xr ptrace 2 ,
.Xr environ 7 ,
.Xr script 7
.Sh COMPATIBILITY .Sh COMPATIBILITY
Historically, the default path for the Historically, the default path for the
.Fn execlp .Fn execlp
@ -251,6 +224,33 @@ and
.Er E2BIG , .Er E2BIG ,
upon which they returned. upon which they returned.
They now return if any error other than the ones described above occurs. They now return if any error other than the ones described above occurs.
.Sh ERRORS
.Fn execl ,
.Fn execle ,
.Fn execlp
and
.Fn execvp
may fail and set
.Va errno
for any of the errors specified for the library functions
.Xr execve 2
and
.Xr malloc 3 .
.Pp
.Fn exect
and
.Fn execv
may fail and set
.Va errno
for any of the errors specified for the library function
.Xr execve 2 .
.Sh SEE ALSO
.Xr sh 1 ,
.Xr execve 2 ,
.Xr fork 2 ,
.Xr ptrace 2 ,
.Xr environ 7 ,
.Xr script 7
.Sh STANDARDS .Sh STANDARDS
.Fn execl , .Fn execl ,
.Fn execv , .Fn execv ,