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

Side by Side Diff: chromeos/system/statistics_provider.cc

Issue 382153006: Fix 'except' and 'prefer' spelling. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Drop change to braille_table.js because it fails CQ. Created 6 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chromeos/system/statistics_provider.h" 5 #include "chromeos/system/statistics_provider.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 private: 127 private:
128 DISALLOW_COPY_AND_ASSIGN(StatisticsProviderImpl); 128 DISALLOW_COPY_AND_ASSIGN(StatisticsProviderImpl);
129 }; 129 };
130 130
131 bool StatisticsProviderImpl::WaitForStatisticsLoaded() { 131 bool StatisticsProviderImpl::WaitForStatisticsLoaded() {
132 CHECK(load_statistics_started_); 132 CHECK(load_statistics_started_);
133 if (on_statistics_loaded_.IsSignaled()) 133 if (on_statistics_loaded_.IsSignaled())
134 return true; 134 return true;
135 135
136 // Block if the statistics are not loaded yet. Normally this shouldn't 136 // Block if the statistics are not loaded yet. Normally this shouldn't
137 // happen excpet during OOBE. 137 // happen except during OOBE.
138 base::Time start_time = base::Time::Now(); 138 base::Time start_time = base::Time::Now();
139 base::ThreadRestrictions::ScopedAllowWait allow_wait; 139 base::ThreadRestrictions::ScopedAllowWait allow_wait;
140 on_statistics_loaded_.TimedWait(base::TimeDelta::FromSeconds(kTimeoutSecs)); 140 on_statistics_loaded_.TimedWait(base::TimeDelta::FromSeconds(kTimeoutSecs));
141 141
142 base::TimeDelta dtime = base::Time::Now() - start_time; 142 base::TimeDelta dtime = base::Time::Now() - start_time;
143 if (on_statistics_loaded_.IsSignaled()) { 143 if (on_statistics_loaded_.IsSignaled()) {
144 LOG(ERROR) << "Statistics loaded after waiting " 144 LOG(ERROR) << "Statistics loaded after waiting "
145 << dtime.InMilliseconds() << "ms. "; 145 << dtime.InMilliseconds() << "ms. ";
146 return true; 146 return true;
147 } 147 }
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 return StatisticsProviderImpl::GetInstance(); 323 return StatisticsProviderImpl::GetInstance();
324 } 324 }
325 325
326 // static 326 // static
327 void StatisticsProvider::SetTestProvider(StatisticsProvider* test_provider) { 327 void StatisticsProvider::SetTestProvider(StatisticsProvider* test_provider) {
328 g_test_statistics_provider = test_provider; 328 g_test_statistics_provider = test_provider;
329 } 329 }
330 330
331 } // namespace system 331 } // namespace system
332 } // namespace chromeos 332 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698