From ef6afd241efbd1a30b89a6144240ed5322d87c73 Mon Sep 17 00:00:00 2001 From: Andy Lester Date: Thu, 26 Mar 2020 19:45:12 -0500 Subject: [PATCH] Keep constness of pointer arguments --- Objects/obmalloc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Objects/obmalloc.c b/Objects/obmalloc.c index 3f6f9cf9ca4a49..42e4dda0fa6fd7 100644 --- a/Objects/obmalloc.c +++ b/Objects/obmalloc.c @@ -364,7 +364,7 @@ _PyMem_SetupAllocators(PyMemAllocatorName allocator) static int -pymemallocator_eq(PyMemAllocatorEx *a, PyMemAllocatorEx *b) +pymemallocator_eq(const PyMemAllocatorEx *a, const PyMemAllocatorEx *b) { return (memcmp(a, b, sizeof(PyMemAllocatorEx)) == 0); } @@ -2452,7 +2452,7 @@ _PyObject_DebugDumpAddress(const void *p) } tail = q + nbytes; - fprintf(stderr, " The %d pad bytes at tail=%p are ", SST, (void *)tail); + fprintf(stderr, " The %d pad bytes at tail=%p are ", SST, (const void *)tail); ok = 1; for (i = 0; i < SST; ++i) { if (tail[i] != PYMEM_FORBIDDENBYTE) {