mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-12 04:42:36 -03:00
fuzz: Avoid timeout in bitdeque fuzz target
This commit is contained in:
parent
e864f2e4af
commit
fa642286b8
1 changed files with 3 additions and 4 deletions
|
@ -2,11 +2,10 @@
|
||||||
// Distributed under the MIT software license, see the accompanying
|
// Distributed under the MIT software license, see the accompanying
|
||||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||||
|
|
||||||
#include <util/bitdeque.h>
|
|
||||||
|
|
||||||
#include <random.h>
|
#include <random.h>
|
||||||
#include <test/fuzz/FuzzedDataProvider.h>
|
#include <test/fuzz/FuzzedDataProvider.h>
|
||||||
#include <test/fuzz/util.h>
|
#include <test/fuzz/util.h>
|
||||||
|
#include <util/bitdeque.h>
|
||||||
|
|
||||||
#include <deque>
|
#include <deque>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
@ -54,7 +53,8 @@ FUZZ_TARGET_INIT(bitdeque, InitRandData)
|
||||||
--initlen;
|
--initlen;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (provider.remaining_bytes()) {
|
LIMITED_WHILE(provider.remaining_bytes() > 0, 900)
|
||||||
|
{
|
||||||
{
|
{
|
||||||
assert(deq.size() == bitdeq.size());
|
assert(deq.size() == bitdeq.size());
|
||||||
auto it = deq.begin();
|
auto it = deq.begin();
|
||||||
|
@ -538,5 +538,4 @@ FUZZ_TARGET_INIT(bitdeque, InitRandData)
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue