Skip to content

Commit 312f338

Browse files
committed
fuzz: restrict fopencookie usage to Linux & FreeBSD
Should fix the GCC compilation portion of #29517: bitcoin/bitcoin#29517 (comment). See also: https://www.gnu.org/software/gnulib/manual/html_node/fopencookie.html but note that FreeBSD has supported this function since 11.x.
1 parent 11a1db8 commit 312f338

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/test/fuzz/util.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ FILE* FuzzedFileProvider::open()
272272
[&] {
273273
mode = "a+";
274274
});
275-
#if defined _GNU_SOURCE && !defined __ANDROID__
275+
#if defined _GNU_SOURCE && (defined(__linux__) || defined(__FreeBSD__))
276276
const cookie_io_functions_t io_hooks = {
277277
FuzzedFileProvider::read,
278278
FuzzedFileProvider::write,

0 commit comments

Comments
 (0)