mirror of
https://github.com/systemd/systemd
synced 2024-07-21 18:24:38 +00:00
fundamental: fix compile check for explicit_bzero
Our HAVE_* variables are defined to 0 or 1, so '#if defined(HAVE_*)' is always true.
The variable is not defined when compiling for EFI though, so we need the
additional guard.
Fixup for 3f92dc2fd4
.
(I don't want to do something like add -DHAVE_EXPLICIT_BZERO=0 to the commandline
in src/efi/boot/meson.build, because this quite verbose. Our compilation commandlines
are very long already. Let's instead keep this localized in this one spot in the
source file.)x
This commit is contained in:
parent
5fe34dbfeb
commit
5deb391c6e
|
@ -11,7 +11,7 @@
|
|||
|
||||
#include "macro-fundamental.h"
|
||||
|
||||
#if defined(HAVE_EXPLICIT_BZERO)
|
||||
#if !defined(SD_BOOT) && HAVE_EXPLICIT_BZERO
|
||||
static inline void *explicit_bzero_safe(void *p, size_t l) {
|
||||
if (p && l > 0)
|
||||
explicit_bzero(p, l);
|
||||
|
|
Loading…
Reference in a new issue