From f46431bcbd20d18549100c0561acd026f083bb7d Mon Sep 17 00:00:00 2001 From: "Michael S. Tsirkin" Date: Fri, 9 Jan 2026 03:49:17 -0500 Subject: [PATCH] tests: enable glibc malloc corruption detection Set MALLOC_CHECK_=3 in test environment to detect memory corruption issues like double-free and buffer overflows. When detected, glibc will print a diagnostic and abort the program. Co-Authored-By: Claude Opus 4.5 --- tests/test_env.sh.in | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/test_env.sh.in b/tests/test_env.sh.in index 240ba8e8..e0e326dc 100644 --- a/tests/test_env.sh.in +++ b/tests/test_env.sh.in @@ -3,6 +3,9 @@ top_builddir="@abs_top_builddir@" export PATH="${top_builddir}/src:${PATH}" +# Detect memory corruption (double-free, buffer overflow) in glibc malloc +export MALLOC_CHECK_=3 + prefix="@prefix@" exec_prefix="@exec_prefix@" datarootdir="@datarootdir@" -- 2.47.3