mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-20 08:45:46 +00:00
Bug 1530773
- Add log module and macro for fuzzing. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21251 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
c7022eb656
commit
c15caba3f0
16
tools/fuzzing/interface/FuzzingInterface.cpp
Normal file
16
tools/fuzzing/interface/FuzzingInterface.cpp
Normal file
@ -0,0 +1,16 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
/*
|
||||
* Common code for the unified fuzzing interface
|
||||
*/
|
||||
|
||||
#include "FuzzingInterface.h"
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
LazyLogModule gFuzzingLog("nsFuzzing");
|
||||
|
||||
} // namespace mozilla
|
@ -14,9 +14,15 @@
|
||||
|
||||
#include "FuzzerRegistry.h"
|
||||
#include "mozilla/Assertions.h"
|
||||
#include "mozilla/Logging.h"
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
extern LazyLogModule gFuzzingLog;
|
||||
|
||||
#define FUZZING_LOG(args) \
|
||||
MOZ_LOG(mozilla::gFuzzingLog, mozilla::LogLevel::Verbose, args)
|
||||
|
||||
typedef int (*FuzzingTestFuncRaw)(const uint8_t*, size_t);
|
||||
|
||||
#ifdef __AFL_COMPILER
|
||||
|
@ -10,6 +10,10 @@ EXPORTS += [
|
||||
'FuzzingInterface.h',
|
||||
]
|
||||
|
||||
SOURCES += [
|
||||
'FuzzingInterface.cpp',
|
||||
]
|
||||
|
||||
if CONFIG['JS_STANDALONE']:
|
||||
FINAL_LIBRARY = "js"
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user