Index: testing/libfuzzer/fuzzers/url_parse_fuzzer.cc |
diff --git a/testing/libfuzzer/fuzzers/url_parse_fuzzer.cc b/testing/libfuzzer/fuzzers/url_parse_fuzzer.cc |
index 48df2c878727ffbed62c43745c353d4e86eff8b9..836ddff3bc2e43b321e656db04376c57b6d5f47c 100644 |
--- a/testing/libfuzzer/fuzzers/url_parse_fuzzer.cc |
+++ b/testing/libfuzzer/fuzzers/url_parse_fuzzer.cc |
@@ -2,8 +2,21 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
+#include "base/at_exit.h" |
+#include "base/i18n/icu_util.h" |
#include "url/gurl.h" |
+struct TestCase { |
+ TestCase() { |
+ assert(base::i18n::InitializeICU()); |
aarya
2015/11/21 05:23:03
We usually use CHECK() macros for these.
aizatsky
2015/11/21 06:00:37
Done.
|
+ } |
+ |
+ // used by ICU integration. |
+ base::AtExitManager at_exit_manager; |
+}; |
+ |
+TestCase *test_case = new TestCase(); |
aarya
2015/11/21 05:23:03
nit: * on the left side.
aizatsky
2015/11/21 06:00:37
Done.
|
+ |
// Entry point for LibFuzzer. |
extern "C" int LLVMFuzzerTestOneInput(const unsigned char *data, |
unsigned long size) { |