summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-24 22:30:27 +0000
committerthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-24 22:30:27 +0000
commitc68ce1701346721ff143dea771b1f3f6482ef1a0 (patch)
tree13aa27c42aa767a49a0ce94536f342651a5b3d02 /chrome
parent173ca873f69c128c933310b962972082bb6068e1 (diff)
downloadchromium_src-c68ce1701346721ff143dea771b1f3f6482ef1a0.zip
chromium_src-c68ce1701346721ff143dea771b1f3f6482ef1a0.tar.gz
chromium_src-c68ce1701346721ff143dea771b1f3f6482ef1a0.tar.bz2
Remove 4 static initializers.
Most of them caused by gcc 4.4 being not sufficiently smart. BUG=94925 TEST=none TBR=akalin Review URL: http://codereview.chromium.org/8690005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@111560 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/bookmarks/bookmark_extension_api.cc23
-rw-r--r--chrome/browser/sync/syncable/directory_backing_store.cc2
2 files changed, 10 insertions, 15 deletions
diff --git a/chrome/browser/bookmarks/bookmark_extension_api.cc b/chrome/browser/bookmarks/bookmark_extension_api.cc
index b6889ae..6c157ac 100644
--- a/chrome/browser/bookmarks/bookmark_extension_api.cc
+++ b/chrome/browser/bookmarks/bookmark_extension_api.cc
@@ -794,6 +794,15 @@ class BookmarksQuotaLimitFactory {
private:
static void BuildWithMappers(QuotaLimitHeuristics* heuristics,
BucketMapper* short_mapper, BucketMapper* long_mapper) {
+ const Config kShortLimitConfig = {
+ 2, // 2 tokens per interval.
+ TimeDelta::FromMinutes(1) // 1 minute long refill interval.
+ };
+ const Config kLongLimitConfig = {
+ 100, // 100 tokens per interval.
+ TimeDelta::FromHours(1) // 1 hour long refill interval.
+ };
+
TimedLimit* timed = new TimedLimit(kLongLimitConfig, long_mapper);
// A max of two operations per minute, sustained over 10 minutes.
SustainedLimit* sustained = new SustainedLimit(TimeDelta::FromMinutes(10),
@@ -802,23 +811,9 @@ class BookmarksQuotaLimitFactory {
heuristics->push_back(sustained);
}
- // The quota configurations used for all BookmarkFunctions.
- static const Config kShortLimitConfig;
- static const Config kLongLimitConfig;
-
DISALLOW_IMPLICIT_CONSTRUCTORS(BookmarksQuotaLimitFactory);
};
-const Config BookmarksQuotaLimitFactory::kShortLimitConfig = {
- 2, // 2 tokens per interval.
- TimeDelta::FromMinutes(1) // 1 minute long refill interval.
-};
-
-const Config BookmarksQuotaLimitFactory::kLongLimitConfig = {
- 100, // 100 tokens per interval.
- TimeDelta::FromHours(1) // 1 hour long refill interval.
-};
-
// And finally, building the individual heuristics for each function.
void RemoveBookmarkFunction::GetQuotaLimitHeuristics(
QuotaLimitHeuristics* heuristics) const {
diff --git a/chrome/browser/sync/syncable/directory_backing_store.cc b/chrome/browser/sync/syncable/directory_backing_store.cc
index 1040f10..be6ead5 100644
--- a/chrome/browser/sync/syncable/directory_backing_store.cc
+++ b/chrome/browser/sync/syncable/directory_backing_store.cc
@@ -30,7 +30,7 @@
// is calling SaveChanges. In the worst case scenario, the user can put his
// laptop to sleep during db contention, and wake up the laptop days later, so
// infinity seems like the best choice here.
-const int kDirectoryBackingStoreBusyTimeoutMs = std::numeric_limits<int>::max();
+const int kDirectoryBackingStoreBusyTimeoutMs = INT_MAX;
using std::string;