diff options
author | van Hauser <vh@thc.org> | 2023-12-23 22:07:32 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-23 22:07:32 +0100 |
commit | 3c0cfd82bccc8e44f01f76628209aecfc8f2aacf (patch) | |
tree | a0d53cfec4be6cdffbd985871171bee6cd6f29b2 /instrumentation/SanitizerCoveragePCGUARD.so.cc | |
parent | 27d05f3c216e18163236efa42b630a5b3784d2e9 (diff) | |
parent | df0638ab87a37f0a3604f5a95a4164153a3bd582 (diff) | |
download | afl++-3c0cfd82bccc8e44f01f76628209aecfc8f2aacf.tar.gz |
Merge pull request #1940 from devnexen/llvm_18_build_fix
llvm 18 build fixes.
Diffstat (limited to 'instrumentation/SanitizerCoveragePCGUARD.so.cc')
-rw-r--r-- | instrumentation/SanitizerCoveragePCGUARD.so.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/instrumentation/SanitizerCoveragePCGUARD.so.cc b/instrumentation/SanitizerCoveragePCGUARD.so.cc index 588eb950..1c019d26 100644 --- a/instrumentation/SanitizerCoveragePCGUARD.so.cc +++ b/instrumentation/SanitizerCoveragePCGUARD.so.cc @@ -572,7 +572,11 @@ void ModuleSanitizerCoverageAFL::instrumentFunction( if (!isInInstrumentList(&F, FMNAME)) return; if (F.getName().find(".module_ctor") != std::string::npos) return; // Should not instrument sanitizer init functions. +#if LLVM_VERSION_MAJOR >= 18 + if (F.getName().starts_with("__sanitizer_")) +#else if (F.getName().startswith("__sanitizer_")) +#endif return; // Don't instrument __sanitizer_* callbacks. // Don't touch available_externally functions, their actual body is elewhere. if (F.getLinkage() == GlobalValue::AvailableExternallyLinkage) return; |