Home | History | Annotate | Download | only in libfuzzer
      1 // Copyright 2017 The PDFium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #include "core/fxcrt/cfx_widetextbuf.h"
      6 #include "core/fxcrt/fx_string.h"
      7 #include "xfa/fxfa/fm2js/cxfa_fmparser.h"
      8 
      9 extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
     10   WideString input = WideString::FromUTF8(ByteStringView(data, size));
     11 
     12   CXFA_FMParser parser(input.AsStringView());
     13   parser.Parse();
     14 
     15   return 0;
     16 }
     17