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

Side by Side Diff: components/component_updater/component_updater_paths.cc

Issue 1853753003: Certificate Transparency: New component for obtaining fresh STHs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing compilation errors on ChromeOS Created 4 years, 8 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 "components/component_updater/component_updater_paths.h" 5 #include "components/component_updater/component_updater_paths.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 9
10 namespace component_updater { 10 namespace component_updater {
(...skipping 29 matching lines...) Expand all
40 break; 40 break;
41 case DIR_SW_REPORTER: 41 case DIR_SW_REPORTER:
42 cur = cur.Append(FILE_PATH_LITERAL("SwReporter")); 42 cur = cur.Append(FILE_PATH_LITERAL("SwReporter"));
43 break; 43 break;
44 case DIR_COMPONENT_EV_WHITELIST: 44 case DIR_COMPONENT_EV_WHITELIST:
45 cur = cur.Append(FILE_PATH_LITERAL("EVWhitelist")); 45 cur = cur.Append(FILE_PATH_LITERAL("EVWhitelist"));
46 break; 46 break;
47 case DIR_SUPERVISED_USER_WHITELISTS: 47 case DIR_SUPERVISED_USER_WHITELISTS:
48 cur = cur.Append(FILE_PATH_LITERAL("SupervisedUserWhitelists")); 48 cur = cur.Append(FILE_PATH_LITERAL("SupervisedUserWhitelists"));
49 break; 49 break;
50 case DIR_CERT_TRANS_TREE_STATES:
51 cur = cur.Append(FILE_PATH_LITERAL("CertificateTransparency"));
52 break;
50 default: 53 default:
51 return false; 54 return false;
52 } 55 }
53 56
54 *result = cur; 57 *result = cur;
55 return true; 58 return true;
56 } 59 }
57 60
58 // This cannot be done as a static initializer sadly since Visual Studio will 61 // This cannot be done as a static initializer sadly since Visual Studio will
59 // eliminate this object file if there is no direct entry point into it. 62 // eliminate this object file if there is no direct entry point into it.
60 void RegisterPathProvider(int components_root_key) { 63 void RegisterPathProvider(int components_root_key) {
61 DCHECK_EQ(g_components_root_key, -1); 64 DCHECK_EQ(g_components_root_key, -1);
62 DCHECK_GT(components_root_key, 0); 65 DCHECK_GT(components_root_key, 0);
63 DCHECK(components_root_key < PATH_START || components_root_key > PATH_END); 66 DCHECK(components_root_key < PATH_START || components_root_key > PATH_END);
64 67
65 g_components_root_key = components_root_key; 68 g_components_root_key = components_root_key;
66 PathService::RegisterProvider(PathProvider, PATH_START, PATH_END); 69 PathService::RegisterProvider(PathProvider, PATH_START, PATH_END);
67 } 70 }
68 71
69 } // namespace component_updater 72 } // namespace component_updater
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698