summaryrefslogtreecommitdiff
path: root/src/lib/libc/stdlib/malloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libc/stdlib/malloc.c')
-rw-r--r--src/lib/libc/stdlib/malloc.c15
1 files changed, 2 insertions, 13 deletions
diff --git a/src/lib/libc/stdlib/malloc.c b/src/lib/libc/stdlib/malloc.c
index 7bc660525b..34b2bb5e66 100644
--- a/src/lib/libc/stdlib/malloc.c
+++ b/src/lib/libc/stdlib/malloc.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: malloc.c,v 1.287 2023/06/22 11:04:16 otto Exp $ */ 1/* $OpenBSD: malloc.c,v 1.288 2023/06/23 05:26:45 otto Exp $ */
2/* 2/*
3 * Copyright (c) 2008, 2010, 2011, 2016, 2023 Otto Moerbeek <otto@drijf.net> 3 * Copyright (c) 2008, 2010, 2011, 2016, 2023 Otto Moerbeek <otto@drijf.net>
4 * Copyright (c) 2012 Matthew Dempsky <matthew@openbsd.org> 4 * Copyright (c) 2012 Matthew Dempsky <matthew@openbsd.org>
@@ -255,11 +255,7 @@ void malloc_dump(void);
255PROTO_NORMAL(malloc_dump); 255PROTO_NORMAL(malloc_dump);
256static void malloc_exit(void); 256static void malloc_exit(void);
257#endif 257#endif
258#define CALLER ( \ 258#define CALLER (DO_STATS ? __builtin_return_address(0) : NULL)
259 DO_STATS == 0 ? NULL : (__builtin_extract_return_addr( \
260 DO_STATS == 1 ? __builtin_return_address(0) : \
261 DO_STATS == 2 ? __builtin_return_address(1) : \
262 DO_STATS == 3 ? __builtin_return_address(2) : NULL)))
263 259
264/* low bits of r->p determine size: 0 means >= page size and r->size holding 260/* low bits of r->p determine size: 0 means >= page size and r->size holding
265 * real size, otherwise low bits is the bucket + 1 261 * real size, otherwise low bits is the bucket + 1
@@ -369,15 +365,8 @@ omalloc_parseopt(char opt)
369 mopts.malloc_stats = 0; 365 mopts.malloc_stats = 0;
370 break; 366 break;
371 case 'D': 367 case 'D':
372 case '1':
373 mopts.malloc_stats = 1; 368 mopts.malloc_stats = 1;
374 break; 369 break;
375 case '2':
376 mopts.malloc_stats = 2;
377 break;
378 case '3':
379 mopts.malloc_stats = 3;
380 break;
381#endif /* MALLOC_STATS */ 370#endif /* MALLOC_STATS */
382 case 'f': 371 case 'f':
383 mopts.malloc_freecheck = 0; 372 mopts.malloc_freecheck = 0;