From 07192b31e3cd4e541bc76b45788cf5e5e8faff9f Mon Sep 17 00:00:00 2001 From: Guillem Jover Date: Wed, 5 Apr 2023 00:01:42 +0200 Subject: [PATCH] test: Disable blank_stack_side_effects() on non-Hurd systems This code was added to cope with Hurd specific behavior, but it is causing flakiness on containers on some Linux systems. Only enable it where it is currently needed to try to get stability back on CI systems. Closes: #14 --- test/explicit_bzero.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/explicit_bzero.c b/test/explicit_bzero.c index 5ec7592..031aa42 100644 --- a/test/explicit_bzero.c +++ b/test/explicit_bzero.c @@ -138,7 +138,7 @@ populate_secret(char *buf, ssize_t len) static void __attribute__((__noinline__)) blank_stack_side_effects(char *buf, size_t len) { -#ifndef __SANITIZE_ADDRESS__ +#if defined(__GNU__) && !defined(__SANITIZE_ADDRESS__) char scratch[SECRETBYTES * 4]; /* If the read(3) in populate_secret() wrote into the stack, as it