diff --git a/icu4c/source/test/fuzzer/collator_compare_fuzzer.cpp b/icu4c/source/test/fuzzer/collator_compare_fuzzer.cpp index a6663f0c0b17..73e1c0e710ea 100644 --- a/icu4c/source/test/fuzzer/collator_compare_fuzzer.cpp +++ b/icu4c/source/test/fuzzer/collator_compare_fuzzer.cpp @@ -39,9 +39,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) { } std::unique_ptr compbuff1(new char16_t[size/4]); std::memcpy(compbuff1.get(), data, (size/4)*2); - data = data + size/2; std::unique_ptr compbuff2(new char16_t[size/4]); - std::memcpy(compbuff2.get(), data, (size/4)*2); + std::memcpy(compbuff2.get(), data + size/2, (size/4)*2); icu::LocalPointer fuzzCollator(