summaryrefslogtreecommitdiff
path: root/testing
diff options
context:
space:
mode:
Diffstat (limited to 'testing')
-rw-r--r--testing/libfuzzer/pdf_xml_fuzzer.cc6
1 files changed, 2 insertions, 4 deletions
diff --git a/testing/libfuzzer/pdf_xml_fuzzer.cc b/testing/libfuzzer/pdf_xml_fuzzer.cc
index 8284bc6ce7..1f368699f4 100644
--- a/testing/libfuzzer/pdf_xml_fuzzer.cc
+++ b/testing/libfuzzer/pdf_xml_fuzzer.cc
@@ -51,10 +51,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
if (!safe_size.IsValid())
return 0;
- CFX_WideString input =
- CFX_WideString::FromUTF8(CFX_ByteStringC(data, safe_size.ValueOrDie()));
- CFX_RetainPtr<IFGAS_Stream> stream =
- IFGAS_Stream::CreateWideStringReadStream(input);
+ CFX_RetainPtr<IFGAS_Stream> stream = IFGAS_Stream::CreateReadStream(
+ IFX_MemoryStream::Create(const_cast<uint8_t*>(data), size));
if (!stream)
return 0;