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 <string.h> 6 7 #include "public/fpdfview.h" 8 9 // Initialize the library once for all runs of the fuzzer. 10 struct TestCase { TestCaseTestCase11 TestCase() { 12 memset(&config, '\0', sizeof(config)); 13 config.version = 2; 14 config.m_pUserFontPaths = nullptr; 15 config.m_pIsolate = nullptr; 16 config.m_v8EmbedderSlot = 0; 17 FPDF_InitLibraryWithConfig(&config); 18 } 19 FPDF_LIBRARY_CONFIG config; 20 }; 21 static TestCase* testCase = new TestCase(); 22