blob: c157c6190c5d756b7357629ad1ce9a115afd7cf2 [file] [log] [blame]
//===- MutagenUtilPosix.cpp - Misc utils for Posix. -----------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
// Misc utils implementation using Posix API.
//===----------------------------------------------------------------------===//
#include "FuzzerPlatform.h"
#if (LIBFUZZER_POSIX || LIBFUZZER_FUCHSIA)
#include <cstring>
namespace mutagen {
const void *SearchMemory(const void *Data, size_t DataLen, const void *Patt,
size_t PattLen) {
return memmem(Data, DataLen, Patt, PattLen);
}
} // namespace mutagen
#endif // (LIBFUZZER_POSIX || LIBFUZZER_FUCHSIA)