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

Unified Diff: chrome/common/child_process_logging.h

Issue 3186028: Make crash reporting client_id accessible through child_process_logging. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: address mark's feedback Created 10 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 | « chrome/browser/browser_child_process_host.cc ('k') | chrome/common/child_process_logging_linux.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/child_process_logging.h
diff --git a/chrome/common/child_process_logging.h b/chrome/common/child_process_logging.h
index 6de7bfe69eeb1775d928d530b33a24f310d3eff6..bdc5a448309a9701aae06fab7bf2aa4e60eed54e 100644
--- a/chrome/common/child_process_logging.h
+++ b/chrome/common/child_process_logging.h
@@ -23,6 +23,13 @@ static const int kMaxReportedActiveExtensions = 10;
namespace child_process_logging {
+#if defined(OS_LINUX)
+// These are declared here so the crash reporter can access them directly in
+// compromised context without going through the standard library.
+extern char g_active_url[];
+extern char g_client_id[];
+#endif
+
// Sets the URL that is logged if the child process crashes. Use GURL() to clear
// the URL.
void SetActiveURL(const GURL& url);
@@ -30,6 +37,10 @@ void SetActiveURL(const GURL& url);
// Sets the Client ID that is used as GUID if a Chrome process crashes.
void SetClientId(const std::string& client_id);
+// Gets the Client ID to be used as GUID for crash reporting. Returns the client
+// id in |client_id| if it's known, an empty string otherwise.
+std::string GetClientId();
+
// Sets the list of "active" extensions in this process. We overload "active" to
// mean different things depending on the process type:
// - browser: all enabled extensions
« no previous file with comments | « chrome/browser/browser_child_process_host.cc ('k') | chrome/common/child_process_logging_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698