aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfanquake <fanquake@gmail.com>2024-12-09 17:01:10 +0000
committerAva Chow <github@achow101.com>2024-12-11 11:41:27 -0500
commit2835158be0410fe82a56752d9ffe60e2a77dc0cd (patch)
tree0d77d7d93a0b861c06ca8e8a1250f1b1cf66fba5
parentd6b225f1652526cb053ec32c8ff09160d5a759c5 (diff)
fuzz: add cstdlib to FuzzedDataProvider
Same as https://github.com/llvm/llvm-project/pull/113951. Avoids compile failures under clang-20 & `D_LIBCPP_REMOVE_TRANSITIVE_INCLUDES`: ```bash In file included from /bitcoin/src/test/fuzz/addition_overflow.cpp:5: /bitcoin/src/test/fuzz/FuzzedDataProvider.h:209:5: error: use of undeclared identifier 'abort' 209 | abort(); | ^ /bitcoin/src/test/fuzz/FuzzedDataProvider.h:250:5: error: use of undeclared identifier 'abort' 250 | abort(); ``` Github-Pull: bitcoin/bitcoin#31448 Rebased-From: bb7e686341e437b2e7aae887827710918c00ae0f
-rw-r--r--src/test/fuzz/FuzzedDataProvider.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/fuzz/FuzzedDataProvider.h b/src/test/fuzz/FuzzedDataProvider.h
index 5903ed8379..e57b95b630 100644
--- a/src/test/fuzz/FuzzedDataProvider.h
+++ b/src/test/fuzz/FuzzedDataProvider.h
@@ -18,6 +18,7 @@
#include <climits>
#include <cstddef>
#include <cstdint>
+#include <cstdlib>
#include <cstring>
#include <initializer_list>
#include <limits>