fuzz: fix vector size problem in system fuzzer

Co-authored-by: Pieter Wuille <pieter.wuille@gmail.com>
pull/18917/head
Harris 5 years ago
parent 5b24f6084e
commit 095bc9a106
No known key found for this signature in database
GPG Key ID: 262685BC78ED11FB

@ -85,7 +85,7 @@ void test_one_input(const std::vector<uint8_t>& buffer)
case 7: { case 7: {
const std::vector<std::string> random_arguments = ConsumeRandomLengthStringVector(fuzzed_data_provider); const std::vector<std::string> random_arguments = ConsumeRandomLengthStringVector(fuzzed_data_provider);
std::vector<const char*> argv; std::vector<const char*> argv;
argv.resize(random_arguments.size()); argv.reserve(random_arguments.size());
for (const std::string& random_argument : random_arguments) { for (const std::string& random_argument : random_arguments) {
argv.push_back(random_argument.c_str()); argv.push_back(random_argument.c_str());
} }

Loading…
Cancel
Save