diff options
author | vanhauser-thc <vh@thc.org> | 2021-07-19 10:48:41 +0200 |
---|---|---|
committer | vanhauser-thc <vh@thc.org> | 2021-07-19 10:48:41 +0200 |
commit | cc57cc5f463e9b79980c2087d19b4a1e1360ec52 (patch) | |
tree | 69a89651deefc660b481e9c964f4cb97ab9073b6 /instrumentation/afl-llvm-dict2file.so.cc | |
parent | 3d1cc8ec57f0bf07d7834b652ec2db24e7914624 (diff) | |
parent | c55f7af65700e3d11c368072d39ba6670efa477b (diff) | |
download | afl++-cc57cc5f463e9b79980c2087d19b4a1e1360ec52.tar.gz |
fix merge conflicts
Diffstat (limited to 'instrumentation/afl-llvm-dict2file.so.cc')
-rw-r--r-- | instrumentation/afl-llvm-dict2file.so.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/instrumentation/afl-llvm-dict2file.so.cc b/instrumentation/afl-llvm-dict2file.so.cc index e2b44b21..58f01920 100644 --- a/instrumentation/afl-llvm-dict2file.so.cc +++ b/instrumentation/afl-llvm-dict2file.so.cc @@ -154,6 +154,7 @@ bool AFLdict2filePass::runOnModule(Module &M) { for (auto &F : M) { if (isIgnoreFunction(&F)) continue; + if (!isInInstrumentList(&F) || !F.size()) { continue; } /* Some implementation notes. * @@ -428,6 +429,12 @@ bool AFLdict2filePass::runOnModule(Module &M) { uint64_t literalLength = Str2.length(); uint64_t optLength = ilen->getZExtValue(); + if (optLength > literalLength + 1) { + + optLength = Str2.length() + 1; + + } + if (literalLength + 1 == optLength) { Str2.append("\0", 1); // add null byte |