summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorotto <>2023-07-01 18:35:14 +0000
committerotto <>2023-07-01 18:35:14 +0000
commitccf79d62f8d8fd51fcd85073f8ae49eb460a86a2 (patch)
treeb62577adecd54a60727b6856be3dabb5ab09f203
parent08b6bd9f45777c2987874303323de008ab014629 (diff)
downloadopenbsd-ccf79d62f8d8fd51fcd85073f8ae49eb460a86a2.tar.gz
openbsd-ccf79d62f8d8fd51fcd85073f8ae49eb460a86a2.tar.bz2
openbsd-ccf79d62f8d8fd51fcd85073f8ae49eb460a86a2.zip
Document that small allocations are initially junked with 0xdf now
-rw-r--r--src/lib/libc/stdlib/malloc.36
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libc/stdlib/malloc.3 b/src/lib/libc/stdlib/malloc.3
index 88a8264da5..b700add823 100644
--- a/src/lib/libc/stdlib/malloc.3
+++ b/src/lib/libc/stdlib/malloc.3
@@ -30,9 +30,9 @@
30.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31.\" SUCH DAMAGE. 31.\" SUCH DAMAGE.
32.\" 32.\"
33.\" $OpenBSD: malloc.3,v 1.136 2023/06/30 06:24:58 otto Exp $ 33.\" $OpenBSD: malloc.3,v 1.137 2023/07/01 18:35:14 otto Exp $
34.\" 34.\"
35.Dd $Mdocdate: June 30 2023 $ 35.Dd $Mdocdate: July 1 2023 $
36.Dt MALLOC 3 36.Dt MALLOC 3
37.Os 37.Os
38.Sh NAME 38.Sh NAME
@@ -325,7 +325,7 @@ Increase the junk level by one if it is smaller than 2.
325Decrease the junk level by one if it is larger than 0. 325Decrease the junk level by one if it is larger than 0.
326Junking writes some junk bytes into the area allocated. 326Junking writes some junk bytes into the area allocated.
327Junk is bytes of 0xdb when allocating; 327Junk is bytes of 0xdb when allocating;
328freed allocations are filled with 0xdf. 328small allocations are initially junked with 0xdf as are freed allocations.
329By default the junk level is 1: after free, 329By default the junk level is 1: after free,
330small chunks are completely junked; 330small chunks are completely junked;
331for pages the first part is junked. 331for pages the first part is junked.