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

Unified Diff: util/win/exception_handler_server_test.cc

Issue 1314093002: Refactor handler/main for Windows, implement CrashHandlerExceptionServer (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@crash-handler-exe
Patch Set: fixes2 Created 5 years, 3 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
« no previous file with comments | « util/win/exception_handler_server.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: util/win/exception_handler_server_test.cc
diff --git a/util/win/exception_handler_server_test.cc b/util/win/exception_handler_server_test.cc
index fd366b03cae0ef2686bf95658f0b1cc1ad4e1f99..0c6a47995875d9cc105b9bec8a0c29a39b1c7226 100644
--- a/util/win/exception_handler_server_test.cc
+++ b/util/win/exception_handler_server_test.cc
@@ -36,16 +36,19 @@ namespace {
// Runs the ExceptionHandlerServer on a background thread.
class RunServerThread : public Thread {
public:
- // Instantiates a thread which will invoke server->Run(pipe_name).
- RunServerThread(ExceptionHandlerServer* server, const std::string& pipe_name)
- : server_(server), pipe_name_(pipe_name) {}
+ // Instantiates a thread which will invoke server->Run(delegate, pipe_name).
+ RunServerThread(ExceptionHandlerServer* server,
+ ExceptionHandlerServer::Delegate* delegate,
+ const std::string& pipe_name)
+ : server_(server), delegate_(delegate), pipe_name_(pipe_name) {}
~RunServerThread() override {}
private:
// Thread:
- void ThreadMain() override { server_->Run(pipe_name_); }
+ void ThreadMain() override { server_->Run(delegate_, pipe_name_); }
ExceptionHandlerServer* server_;
+ ExceptionHandlerServer::Delegate* delegate_;
std::string pipe_name_;
DISALLOW_COPY_AND_ASSIGN(RunServerThread);
@@ -81,8 +84,8 @@ class ExceptionHandlerServerTest : public testing::Test {
base::StringPrintf("%08x", GetCurrentProcessId())),
server_ready_(CreateEvent(nullptr, false, false, nullptr)),
delegate_(server_ready_.get()),
- server_(&delegate_),
- server_thread_(&server_, pipe_name_) {}
+ server_(),
+ server_thread_(&server_, &delegate_, pipe_name_) {}
TestDelegate& delegate() { return delegate_; }
ExceptionHandlerServer& server() { return server_; }
« no previous file with comments | « util/win/exception_handler_server.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698