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

Unified Diff: syzygy/integration_tests/instrument_integration_test.cc

Issue 2993173002: Fix an ownership issue in ScopedAgentLogger (Closed)
Patch Set: Fix an ownership issue in ScopedAgentLogger Created 3 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: syzygy/integration_tests/instrument_integration_test.cc
diff --git a/syzygy/integration_tests/instrument_integration_test.cc b/syzygy/integration_tests/instrument_integration_test.cc
index 1baf929241e3ba941a783aaf83a56769b3689792..99284e77671ad5bf8e6c28e2e7ca30e8402c2a3e 100644
--- a/syzygy/integration_tests/instrument_integration_test.cc
+++ b/syzygy/integration_tests/instrument_integration_test.cc
@@ -96,10 +96,6 @@ struct ScopedAgentLogger {
}
~ScopedAgentLogger() {
- // Clean up the temp directory if we created one.
- if (!temp_dir_.empty())
- base::DeleteFile(temp_dir_, true);
-
if (nul_) {
::CloseHandle(nul_);
nul_ = NULL;
@@ -168,8 +164,11 @@ struct ScopedAgentLogger {
base::FilePath agent_logger_;
std::string instance_id_;
- // Modified by Start and Stop.
+ // The temp directory used by this logger. This is owned by the object that
+ // owns this logger.
base::FilePath temp_dir_;
+
+ // Modified by Start and Stop.
base::FilePath log_file_;
base::Process process_;
HANDLE nul_;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698