Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(26)

Side by Side Diff: ipc/ipc_security_test_util.cc

Issue 712713002: IPC: a way for browsertests to simulate the appearance of a malicious IPC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@interstitial
Patch Set: Move test util to ipc test support library Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ipc/ipc_security_test_util.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium 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 "ipc/ipc_security_test_util.h"
6
7 #include "base/bind.h"
8 #include "base/bind_helpers.h"
9 #include "base/run_loop.h"
10 #include "ipc/ipc_channel_proxy.h"
11
12 namespace IPC {
13
14 void IpcSecurityTestUtil::PwnMessageReceived(ChannelProxy* channel,
15 const IPC::Message& message) {
16 base::RunLoop run_loop;
17 channel->context()->ipc_task_runner()->PostTaskAndReply(
18 FROM_HERE, base::Bind(base::IgnoreResult(
19 &IPC::ChannelProxy::Context::OnMessageReceived),
Tom Sepez 2014/11/08 00:26:31 nit: indentation style. I thought the deal was to
ncarter (slow) 2014/11/08 00:43:05 This was from clang-format. But I agree this was h
20 channel->context(), message),
21 run_loop.QuitClosure());
22 run_loop.Run();
23 }
24
25 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/ipc_security_test_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698