Commit b3acc6a2 authored by Alex Ilin's avatar Alex Ilin Committed by Commit Bot

Remove base::SharedMemoryHandle from ipc_fuzzer

base::SharedMemoryHandle is deprecated and will be removed soon.

Bug: 795291
Change-Id: Iacce3af560cacc3baafaf401c6e1273141ae7a39
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1919156
Auto-Submit: Alex Ilin <alexilin@chromium.org>
Reviewed-by: default avatarMartin Barbella <mbarbella@chromium.org>
Commit-Queue: Alex Ilin <alexilin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#715946}
parent 98dc7a60
......@@ -11,7 +11,6 @@
#include "base/compiler_specific.h"
#include "base/memory/ptr_util.h"
#include "base/memory/shared_memory_handle.h"
#include "base/stl_util.h"
#include "base/strings/string_util.h"
#include "base/unguessable_token.h"
......@@ -444,18 +443,6 @@ struct FuzzTraits<base::NullableString16> {
}
};
#if defined(OS_WIN) || defined(OS_MACOSX)
template <>
struct FuzzTraits<base::SharedMemoryHandle> {
static bool Fuzz(base::SharedMemoryHandle* p, Fuzzer* fuzzer) {
// This generates an invalid SharedMemoryHandle. Generating a valid
// SharedMemoryHandle requires setting/knowing state in both the sending and
// receiving process, which is not currently possible.
return true;
}
};
#endif // defined(OS_WIN) || defined(OS_MACOSX)
template <>
struct FuzzTraits<base::Time> {
static bool Fuzz(base::Time* p, Fuzzer* fuzzer) {
......@@ -1080,9 +1067,6 @@ struct FuzzTraits<std::unique_ptr<IPC::Message>> {
}
};
#if !defined(OS_WIN)
// PlatformfileForTransit is just SharedMemoryHandle on Windows, which already
// has a trait, see ipc/ipc_platform_file.h
template <>
struct FuzzTraits<IPC::PlatformFileForTransit> {
static bool Fuzz(IPC::PlatformFileForTransit* p, Fuzzer* fuzzer) {
......@@ -1091,7 +1075,6 @@ struct FuzzTraits<IPC::PlatformFileForTransit> {
return true;
}
};
#endif
template <>
struct FuzzTraits<IPC::ChannelHandle> {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment