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

Unified Diff: ipc/ipc_channel_win.cc

Issue 7486007: Fix NamedProxyLauncher on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ... Created 9 years, 5 months 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 side-by-side diff with in-line comments
Download patch
« chrome/test/automation/proxy_launcher.cc ('K') | « ipc/ipc_channel_win.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ipc/ipc_channel_win.cc
diff --git a/ipc/ipc_channel_win.cc b/ipc/ipc_channel_win.cc
index e56235da3d16fba598bfdc56375b8373e2f66955..e310217d8d06af222b88c32d9cc407f9264c1755 100644
--- a/ipc/ipc_channel_win.cc
+++ b/ipc/ipc_channel_win.cc
@@ -93,16 +93,10 @@ bool Channel::ChannelImpl::Send(Message* message) {
return true;
}
-const std::wstring Channel::ChannelImpl::PipeName(
- const std::string& channel_id) const {
- std::string name("\\\\.\\pipe\\chrome.");
- return ASCIIToWide(name.append(channel_id));
-}
-
bool Channel::ChannelImpl::CreatePipe(const IPC::ChannelHandle &channel_handle,
Mode mode) {
DCHECK_EQ(INVALID_HANDLE_VALUE, pipe_);
- const std::wstring pipe_name = PipeName(channel_handle.name);
+ const std::wstring pipe_name = PipeNameFromChannelId(channel_handle.name);
if (mode & MODE_SERVER_FLAG) {
pipe_ = CreateNamedPipeW(pipe_name.c_str(),
PIPE_ACCESS_DUPLEX | FILE_FLAG_OVERLAPPED |
@@ -384,6 +378,11 @@ void Channel::ChannelImpl::OnIOCompleted(MessageLoopForIO::IOContext* context,
}
}
+const std::wstring PipeNameFromChannelId(const std::string& channel_id) {
+ std::string name("\\\\.\\pipe\\chrome.");
+ return ASCIIToWide(name.append(channel_id));
+}
+
//------------------------------------------------------------------------------
// Channel's methods simply call through to ChannelImpl.
Channel::Channel(const IPC::ChannelHandle &channel_handle, Mode mode,
« chrome/test/automation/proxy_launcher.cc ('K') | « ipc/ipc_channel_win.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698