Files
seta75D ff309bfe1c Init
2021-10-11 18:37:13 -03:00

35 lines
935 B
Plaintext

.\" @(#)zero.4s 1.1 94/10/31 SMI;
.TH ZERO 4S "9 October 1987"
.SH NAME
zero \- source of zeroes
.SH SYNOPSIS
None; included with standard system.
.IX "unnamed memory" "" "\fLzero\fP \(em source of zeroed unnamed memory"
.SH DESCRIPTION
.LP
A zero special file is a source of zeroed unnamed memory.
.LP
Reads from a zero special file always return a buffer full of zeroes. The
file is of infinite length.
.LP
Writes to a zero special file are always successful, but the data written is
ignored.
.LP
Mapping a zero special file creates a zero-initialized unnamed memory
object of a length equal to the length of the mapping and rounded up to the
nearest page size as returned by
.BR getpagesize (2).
Multiple processes
can share such a zero special file object provided a common ancestor mapped
the object
.BR \s-1MAP_SHARED\s0 .
.SH FILES
.PD 0
.TP 20
.B /dev/zero
.PD
.SH SEE ALSO
.BR fork (2V),
.BR getpagesize (2),
.BR mmap (2)