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

Side by Side Diff: tools/ipc_fuzzer/message_replay/replay_process.cc

Issue 2476883002: Remove obsolete methods from IPC::Channel and related classes. (Closed)
Patch Set: Created 4 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "tools/ipc_fuzzer/message_replay/replay_process.h" 5 #include "tools/ipc_fuzzer/message_replay/replay_process.h"
6 6
7 #include <limits.h> 7 #include <limits.h>
8 #include <string> 8 #include <string>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 logging::InitLogging(settings); 81 logging::InitLogging(settings);
82 82
83 // Make sure to initialize Mojo before starting the IO thread. 83 // Make sure to initialize Mojo before starting the IO thread.
84 InitializeMojo(); 84 InitializeMojo();
85 85
86 io_thread_.StartWithOptions( 86 io_thread_.StartWithOptions(
87 base::Thread::Options(base::MessageLoop::TYPE_IO, 0)); 87 base::Thread::Options(base::MessageLoop::TYPE_IO, 0));
88 88
89 #if defined(OS_POSIX) 89 #if defined(OS_POSIX)
90 base::GlobalDescriptors* g_fds = base::GlobalDescriptors::GetInstance(); 90 base::GlobalDescriptors* g_fds = base::GlobalDescriptors::GetInstance();
91 g_fds->Set(kPrimaryIPCChannel,
92 kPrimaryIPCChannel + base::GlobalDescriptors::kBaseDescriptor);
93 g_fds->Set(kMojoIPCChannel, 91 g_fds->Set(kMojoIPCChannel,
94 kMojoIPCChannel + base::GlobalDescriptors::kBaseDescriptor); 92 kMojoIPCChannel + base::GlobalDescriptors::kBaseDescriptor);
95 #endif 93 #endif
96 94
97 mojo_ipc_support_.reset( 95 mojo_ipc_support_.reset(
98 new mojo::edk::ScopedIPCSupport(io_thread_.task_runner())); 96 new mojo::edk::ScopedIPCSupport(io_thread_.task_runner()));
99 InitializeMojoIPCChannel(); 97 InitializeMojoIPCChannel();
100 98
101 return true; 99 return true;
102 } 100 }
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 return true; 146 return true;
149 } 147 }
150 148
151 void ReplayProcess::OnChannelError() { 149 void ReplayProcess::OnChannelError() {
152 LOG(ERROR) << "Channel error, quitting after " 150 LOG(ERROR) << "Channel error, quitting after "
153 << message_index_ << " messages"; 151 << message_index_ << " messages";
154 base::MessageLoop::current()->QuitWhenIdle(); 152 base::MessageLoop::current()->QuitWhenIdle();
155 } 153 }
156 154
157 } // namespace ipc_fuzzer 155 } // namespace ipc_fuzzer
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698