>From 73dbe66c0ed68ae588223639a2ba93f6a727b704 Mon Sep 17 00:00:00 2001 From: Samuel Marks <807580+samuelma...@users.noreply.github.com> Date: Fri, 23 Aug 2024 16:03:41 -0500 Subject: [PATCH] [src/include/pg_config_manual.h] Guard `CLOBBER_FREED_MEMORY` & `MEMORY_CONTEXT_CHECKING`
--- src/include/pg_config_manual.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/include/pg_config_manual.h b/src/include/pg_config_manual.h index e799c298..1f28d585 100644 --- a/src/include/pg_config_manual.h +++ b/src/include/pg_config_manual.h @@ -261,7 +261,7 @@ * facilitate catching bugs that refer to already-freed values. * Right now, this gets defined automatically if --enable-cassert. */ -#ifdef USE_ASSERT_CHECKING +#if defined(USE_ASSERT_CHECKING) && !defined(CLOBBER_FREED_MEMORY) #define CLOBBER_FREED_MEMORY #endif @@ -270,7 +270,8 @@ * bytes than were allocated). Right now, this gets defined * automatically if --enable-cassert or USE_VALGRIND. */ -#if defined(USE_ASSERT_CHECKING) || defined(USE_VALGRIND) +#if (defined(USE_ASSERT_CHECKING) || defined(USE_VALGRIND)) && \ + !defined(MEMORY_CONTEXT_CHECKING) #define MEMORY_CONTEXT_CHECKING #endif -- 2.43.0 Samuel Marks, PhD https://linkedin.com/in/samuelmarks