Coverage Report

Created: 2026-06-13 06:44

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/libfreehand/src/fuzz/fhfuzzer.cpp
Line
Count
Source
1
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/*
3
 * This file is part of the libfreehand project.
4
 *
5
 * This Source Code Form is subject to the terms of the Mozilla Public
6
 * License, v. 2.0. If a copy of the MPL was not distributed with this
7
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
 */
9
10
#include <cstdint>
11
#include <cstdlib>
12
13
#include <libfreehand/libfreehand.h>
14
15
#include <librevenge-generators/RVNGDummyDrawingGenerator.h>
16
17
#include <librevenge-stream/librevenge-stream.h>
18
19
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
20
1.50M
{
21
1.50M
  librevenge::RVNGStringStream input(data, size);
22
1.50M
  librevenge::RVNGDummyDrawingGenerator generator;
23
1.50M
  libfreehand::FreeHandDocument::parse(&input, &generator);
24
1.50M
  return 0;
25
1.50M
}
26
27
/* vim:set shiftwidth=2 softtabstop=2 expandtab: */