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

Unified Diff: content/zygote/zygote_main_linux.cc

Issue 317503002: AsanCoverage: make the filenames of zygote/gpu coverage files more unique. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments Created 6 years, 7 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 | « content/gpu/gpu_main.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/zygote/zygote_main_linux.cc
diff --git a/content/zygote/zygote_main_linux.cc b/content/zygote/zygote_main_linux.cc
index bae86093614b70e88be396ff75da7394b04069f5..60f08b6ad636760ee03bb8d26df13e9075b109a1 100644
--- a/content/zygote/zygote_main_linux.cc
+++ b/content/zygote/zygote_main_linux.cc
@@ -22,6 +22,7 @@
#include "base/posix/eintr_wrapper.h"
#include "base/posix/unix_domain_socket_linux.h"
#include "base/rand_util.h"
+#include "base/strings/string_number_conversions.h"
#include "base/sys_info.h"
#include "build/build_config.h"
#include "content/common/child_process_sandbox_support_impl_linux.h"
@@ -496,7 +497,10 @@ bool ZygoteMain(const MainFunctionParams& params,
LinuxSandbox* linux_sandbox = LinuxSandbox::GetInstance();
#if defined(ADDRESS_SANITIZER)
- base::ScopedFD sancov_file_fd(__sanitizer_maybe_open_cov_file("zygote"));
+ const std::string sancov_file_name =
+ "zygote." + base::Uint64ToString(base::RandUint64());
+ base::ScopedFD sancov_file_fd(
+ __sanitizer_maybe_open_cov_file(sancov_file_name.c_str()));
int sancov_socket_fds[2] = {-1, -1};
CreateSanitizerCoverageSocketPair(sancov_socket_fds);
linux_sandbox->sanitizer_args()->coverage_sandboxed = 1;
« no previous file with comments | « content/gpu/gpu_main.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698