Index: util/win/exception_handler_server.cc |
diff --git a/util/win/exception_handler_server.cc b/util/win/exception_handler_server.cc |
index aba3ffa0c016494b9a6262b0764ba859a5ee2cca..234d3149ec94333b18425dda926ac66a5a30b50e 100644 |
--- a/util/win/exception_handler_server.cc |
+++ b/util/win/exception_handler_server.cc |
@@ -234,8 +234,9 @@ class ClientData { |
ExceptionHandlerServer::Delegate::~Delegate() { |
} |
-ExceptionHandlerServer::ExceptionHandlerServer() |
- : port_(CreateIoCompletionPort(INVALID_HANDLE_VALUE, nullptr, 0, 1)), |
+ExceptionHandlerServer::ExceptionHandlerServer(const std::string& pipe_name) |
+ : pipe_name_(pipe_name), |
+ port_(CreateIoCompletionPort(INVALID_HANDLE_VALUE, nullptr, 0, 1)), |
clients_lock_(), |
clients_() { |
} |
@@ -243,13 +244,12 @@ ExceptionHandlerServer::ExceptionHandlerServer() |
ExceptionHandlerServer::~ExceptionHandlerServer() { |
} |
-void ExceptionHandlerServer::Run(Delegate* delegate, |
- const std::string& pipe_name) { |
+void ExceptionHandlerServer::Run(Delegate* delegate) { |
uint64_t shutdown_token = base::RandUint64(); |
// We create two pipe instances, so that there's one listening while the |
// PipeServiceProc is processing a registration. |
ScopedKernelHANDLE thread_handles[2]; |
- base::string16 pipe_name_16(base::UTF8ToUTF16(pipe_name)); |
+ base::string16 pipe_name_16(base::UTF8ToUTF16(pipe_name_)); |
for (int i = 0; i < arraysize(thread_handles); ++i) { |
HANDLE pipe = |
CreateNamedPipe(pipe_name_16.c_str(), |
@@ -311,7 +311,7 @@ void ExceptionHandlerServer::Run(Delegate* delegate, |
message.type = ClientToServerMessage::kShutdown; |
message.shutdown.token = shutdown_token; |
ServerToClientMessage response; |
- SendToCrashHandlerServer(base::UTF8ToUTF16(pipe_name), |
+ SendToCrashHandlerServer(pipe_name_16, |
Mark Mentovai
2015/10/29 18:46:46
Saved a conversion here, too.
|
reinterpret_cast<ClientToServerMessage&>(message), |
&response); |
} |