summaryrefslogtreecommitdiffstats
path: root/man2/brk.2
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:09 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 19:41:09 +0000
commit0db324e2e5d9d3347ea0e93138372fb65aac09e6 (patch)
tree1b794022fb98db123c73021e75286a82c116aa7f /man2/brk.2
parentReleasing progress-linux version 6.05.01-1~progress7.99u1. (diff)
downloadmanpages-0db324e2e5d9d3347ea0e93138372fb65aac09e6.tar.xz
manpages-0db324e2e5d9d3347ea0e93138372fb65aac09e6.zip
Merging upstream version 6.7.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'man2/brk.2')
-rw-r--r--man2/brk.218
1 files changed, 9 insertions, 9 deletions
diff --git a/man2/brk.2 b/man2/brk.2
index 2cc61a9..0248459 100644
--- a/man2/brk.2
+++ b/man2/brk.2
@@ -7,7 +7,7 @@
.\" Modified Wed Jul 21 19:52:58 1993 by Rik Faith <faith@cs.unc.edu>
.\" Modified Sun Aug 21 17:40:38 1994 by Rik Faith <faith@cs.unc.edu>
.\"
-.TH brk 2 2023-03-30 "Linux man-pages 6.05.01"
+.TH brk 2 2023-10-31 "Linux man-pages 6.7"
.SH NAME
brk, sbrk \- change data segment size
.SH LIBRARY
@@ -16,16 +16,16 @@ Standard C library
.SH SYNOPSIS
.nf
.B #include <unistd.h>
-.PP
+.P
.BI "int brk(void *" addr );
.BI "void *sbrk(intptr_t " increment );
.fi
-.PP
+.P
.RS -4
Feature Test Macro Requirements for glibc (see
.BR feature_test_macros (7)):
.RE
-.PP
+.P
.BR brk (),
.BR sbrk ():
.nf
@@ -57,14 +57,14 @@ uninitialized data segment).
Increasing the program break has the effect of
allocating memory to the process;
decreasing the break deallocates memory.
-.PP
+.P
.BR brk ()
sets the end of the data segment to the value specified by
.IR addr ,
when that value is reasonable, the system has enough memory,
and the process does not exceed its maximum data size (see
.BR setrlimit (2)).
-.PP
+.P
.BR sbrk ()
increments the program's data space by
.I increment
@@ -82,7 +82,7 @@ On error, \-1 is returned, and
.I errno
is set to
.BR ENOMEM .
-.PP
+.P
On success,
.BR sbrk ()
returns the previous program break.
@@ -113,7 +113,7 @@ the
.BR malloc (3)
memory allocation package is the
portable and comfortable way of allocating memory.
-.PP
+.P
Various systems use various types for the argument of
.BR sbrk ().
Common are \fIint\fP, \fIssize_t\fP, \fIptrdiff_t\fP, \fIintptr_t\fP.
@@ -139,7 +139,7 @@ The glibc wrapper function does some work
(i.e., checks whether the new break is less than
.IR addr )
to provide the 0 and \-1 return values described above.
-.PP
+.P
On Linux,
.BR sbrk ()
is implemented as a library function that uses the