[llvm] r249646 - [libFuzzer] fix 32-bit build
Kostya Serebryany via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 7 17:59:25 PDT 2015
Author: kcc
Date: Wed Oct 7 19:59:25 2015
New Revision: 249646
URL: http://llvm.org/viewvc/llvm-project?rev=249646&view=rev
Log:
[libFuzzer] fix 32-bit build
Modified:
llvm/trunk/lib/Fuzzer/FuzzerMutate.cpp
Modified: llvm/trunk/lib/Fuzzer/FuzzerMutate.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Fuzzer/FuzzerMutate.cpp?rev=249646&r1=249645&r2=249646&view=diff
==============================================================================
--- llvm/trunk/lib/Fuzzer/FuzzerMutate.cpp (original)
+++ llvm/trunk/lib/Fuzzer/FuzzerMutate.cpp Wed Oct 7 19:59:25 2015
@@ -61,7 +61,7 @@ static char RandCh(FuzzerRandomBase &Ran
size_t MutationDispatcher::Mutate_ShuffleBytes(uint8_t *Data, size_t Size,
size_t MaxSize) {
assert(Size);
- size_t ShuffleAmount = Rand(std::min(Size, 8UL)) + 1; // [1,8] and <= Size.
+ size_t ShuffleAmount = Rand(std::min(Size, (size_t)8)) + 1; // [1,8] and <= Size.
size_t ShuffleStart = Rand(Size - ShuffleAmount);
assert(ShuffleStart + ShuffleAmount <= Size);
std::random_shuffle(Data + ShuffleStart, Data + ShuffleStart + ShuffleAmount,
More information about the llvm-commits
mailing list