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

Side by Side Diff: components/variations/variations_seed_store.cc

Issue 1271123003: Componentize VariationsSeedStore and its unittest (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@componentize_variations_prefs
Patch Set: Rebase Created 5 years, 3 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "chrome/browser/metrics/variations/variations_seed_store.h" 5 #include "components/variations/variations_seed_store.h"
6 6
7 #include "base/base64.h" 7 #include "base/base64.h"
8 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
9 #include "base/numerics/safe_math.h" 9 #include "base/numerics/safe_math.h"
10 #include "base/prefs/pref_registry_simple.h" 10 #include "base/prefs/pref_registry_simple.h"
11 #include "base/prefs/pref_service.h" 11 #include "base/prefs/pref_service.h"
12 #include "base/sha1.h" 12 #include "base/sha1.h"
13 #include "base/strings/string_number_conversions.h" 13 #include "base/strings/string_number_conversions.h"
14 #include "components/compression/compression_utils.h" 14 #include "components/compression/compression_utils.h"
15 #include "components/variations/pref_names.h" 15 #include "components/variations/pref_names.h"
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 end_offset += length; 444 end_offset += length;
445 if (!end_offset.IsValid() || end_offset.ValueOrDie() > existing_data_size) 445 if (!end_offset.IsValid() || end_offset.ValueOrDie() > existing_data_size)
446 return false; 446 return false;
447 output->append(existing_data, offset, length); 447 output->append(existing_data, offset, length);
448 } 448 }
449 } 449 }
450 return true; 450 return true;
451 } 451 }
452 452
453 } // namespace chrome_variations 453 } // namespace chrome_variations
OLDNEW
« no previous file with comments | « components/variations/variations_seed_store.h ('k') | components/variations/variations_seed_store_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698