summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibC/stdlib.h
diff options
context:
space:
mode:
authorDaniel Bertalan <dani@danielbertalan.dev>2022-01-12 10:54:09 +0100
committerAndreas Kling <kling@serenityos.org>2022-01-12 14:54:12 +0100
commitc7423dc20b7dbca786ff04d5ea06b7635fe37f21 (patch)
treef419ee59f93e2a6b5329ec1c7d935405b73f36e0 /Userland/Libraries/LibC/stdlib.h
parent9e8c4bb072f1b6c12096327ef9eb0a12b2bb9457 (diff)
downloadserenity-c7423dc20b7dbca786ff04d5ea06b7635fe37f21.zip
LibC: Make the address argument of `malloc_size` a pointer to const
We don't mutate the pointed-to memory, so let's be const correct. Fixes building the `mimalloc` library that's optionally used by the mold linker (note that it isn't enabled yet as I haven't tested it).
Diffstat (limited to 'Userland/Libraries/LibC/stdlib.h')
-rw-r--r--Userland/Libraries/LibC/stdlib.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibC/stdlib.h b/Userland/Libraries/LibC/stdlib.h
index abab2a44cb..cfb7e19729 100644
--- a/Userland/Libraries/LibC/stdlib.h
+++ b/Userland/Libraries/LibC/stdlib.h
@@ -20,7 +20,7 @@ __attribute__((noreturn)) void _abort(void);
__attribute__((malloc)) __attribute__((alloc_size(1))) void* malloc(size_t);
__attribute__((malloc)) __attribute__((alloc_size(1, 2))) void* calloc(size_t nmemb, size_t);
-size_t malloc_size(void*);
+size_t malloc_size(void const*);
size_t malloc_good_size(size_t);
void serenity_dump_malloc_stats(void);
void free(void*);