Index: sandbox/win/tests/common/controller.cc |
diff --git a/sandbox/win/tests/common/controller.cc b/sandbox/win/tests/common/controller.cc |
index 8d3e29dd9600bf643b55cdc46b01d2fe89a70baa..d4a74e08539fa45fca8d3a3fd8876cc79615f2a6 100644 |
--- a/sandbox/win/tests/common/controller.cc |
+++ b/sandbox/win/tests/common/controller.cc |
@@ -6,6 +6,7 @@ |
#include <string> |
+#include "base/memory/ref_counted.h" |
#include "base/memory/shared_memory.h" |
#include "base/process/process.h" |
#include "base/process/process_handle.h" |
@@ -133,15 +134,12 @@ void TestRunner::Init(JobLevel job_level, TokenLevel startup_token, |
} |
TargetPolicy* TestRunner::GetPolicy() { |
- return policy_; |
+ return policy_.get(); |
} |
TestRunner::~TestRunner() { |
if (target_process_.IsValid() && kill_on_destruction_) |
::TerminateProcess(target_process_.Get(), 0); |
- |
- if (policy_) |
- policy_->Release(); |
} |
bool TestRunner::AddRule(TargetPolicy::SubSystem subsystem, |