mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-16 10:20:30 +00:00
mdoc(7) police: tidy up OpenBSD fixes.
This commit is contained in:
parent
3e4f59ce06
commit
89ac4ecce1
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=89428
@ -64,13 +64,11 @@ is non-zero,
|
|||||||
will redirect standard input, standard output, and standard error to
|
will redirect standard input, standard output, and standard error to
|
||||||
.Pa /dev/null .
|
.Pa /dev/null .
|
||||||
.Sh RETURN VALUES
|
.Sh RETURN VALUES
|
||||||
Upon success,
|
.Rv -std daemon
|
||||||
.Fn daemon
|
|
||||||
returns 0; otherwise \-1 is returned.
|
|
||||||
.Sh ERRORS
|
.Sh ERRORS
|
||||||
The function
|
The
|
||||||
.Fn daemon
|
.Fn daemon
|
||||||
may fail and set
|
function may fail and set
|
||||||
.Va errno
|
.Va errno
|
||||||
for any of the errors specified for the library functions
|
for any of the errors specified for the library functions
|
||||||
.Xr fork 2
|
.Xr fork 2
|
||||||
@ -86,14 +84,14 @@ function first appeared in
|
|||||||
.Bx 4.4 .
|
.Bx 4.4 .
|
||||||
.Sh CAVEATS
|
.Sh CAVEATS
|
||||||
Unless the
|
Unless the
|
||||||
.Ar noclose
|
.Fa noclose
|
||||||
argument is non-zero,
|
argument is non-zero,
|
||||||
.Fn daemon
|
.Fn daemon
|
||||||
will close the first three file descriptors and redirect them to
|
will close the first three file descriptors and redirect them to
|
||||||
.Pa /dev/null .
|
.Pa /dev/null .
|
||||||
Normally, these correspond to standard input, standard output, and
|
Normally, these correspond to standard input, standard output, and
|
||||||
standard error.
|
standard error.
|
||||||
However, if any of those file descriptors refer to something else they
|
However, if any of those file descriptors refer to something else, they
|
||||||
will still be closed, resulting in incorrect behavior of the calling program.
|
will still be closed, resulting in incorrect behavior of the calling program.
|
||||||
This can happen if any of standard input, standard output, or standard
|
This can happen if any of standard input, standard output, or standard
|
||||||
error have been closed before the program was run.
|
error have been closed before the program was run.
|
||||||
|
Loading…
Reference in New Issue
Block a user