summaryrefslogtreecommitdiffstats
path: root/chrome_frame/metrics_service.h
diff options
context:
space:
mode:
authorananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-16 00:41:19 +0000
committerananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-16 00:41:19 +0000
commit606e5bf8127fc5780999543e560397c895656a09 (patch)
tree32f6c9e32cba71d1cb877336e676c4b59888324a /chrome_frame/metrics_service.h
parent78945f3af3c1277239215e937edf6bbb6d38dd63 (diff)
downloadchromium_src-606e5bf8127fc5780999543e560397c895656a09.zip
chromium_src-606e5bf8127fc5780999543e560397c895656a09.tar.gz
chromium_src-606e5bf8127fc5780999543e560397c895656a09.tar.bz2
Fixes for a couple of ChromeFrame crashes seen in the latest dev channel build. These
crashes occur in the Chrome HTTP stack which is used for uploading UMA data. I could not repro these crashes though and they seem to occur while posting tasks to a deleted message loop. Currently we create an io thread on the fly for uploading the uma data and destroy it when we are done. To workaround this issue we are attempting to create one IO thread and leave it running. At this point this thread object is leaked as we don't have a good way of stopping this from the IO thread. Added a TODO in the code to this effect. I also added a check for whether the ChromeFrameMetricsDataUploader::Initialize function succeeds as it appears that there are failures on the field due to failure in creating the unnamed window. The ChromeFrame metrics service object is no longer a ThreadLocal object. Review URL: http://codereview.chromium.org/3396005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59594 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/metrics_service.h')
-rw-r--r--chrome_frame/metrics_service.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/chrome_frame/metrics_service.h b/chrome_frame/metrics_service.h
index dd71483..252f716 100644
--- a/chrome_frame/metrics_service.h
+++ b/chrome_frame/metrics_service.h
@@ -35,6 +35,9 @@ class MetricsService : public MetricsServiceBase {
void InitializeMetricsState();
private:
+ // To enable the default traits object to create an instance of this class.
+ friend struct base::DefaultLazyInstanceTraits<MetricsService>;
+
MetricsService();
virtual ~MetricsService();
// The MetricsService has a lifecycle that is stored as a state.
@@ -135,9 +138,6 @@ class MetricsService : public MetricsServiceBase {
// A number that identifies the how many times the app has been launched.
int session_id_;
- static base::LazyInstance<base::ThreadLocalPointer<MetricsService> >
- g_metrics_instance_;
-
PlatformThreadId thread_;
// Indicates if this is the first uma upload from this instance.