OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/policy/configuration_policy_provider_delegate_win.h" | 5 #include "chrome/browser/policy/configuration_policy_provider_delegate_win.h" |
6 | 6 |
| 7 #include <string.h> |
| 8 |
| 9 #include "base/basictypes.h" |
| 10 #include "base/logging.h" |
| 11 #include "base/memory/scoped_ptr.h" |
7 #include "base/string_number_conversions.h" | 12 #include "base/string_number_conversions.h" |
8 #include "base/utf_string_conversions.h" | 13 #include "base/utf_string_conversions.h" |
| 14 #include "base/values.h" |
9 #include "base/win/registry.h" | 15 #include "base/win/registry.h" |
10 #include "policy/policy_constants.h" | 16 #include "policy/policy_constants.h" |
11 | 17 |
12 using base::win::RegKey; | 18 using base::win::RegKey; |
13 | 19 |
14 namespace { | 20 namespace { |
15 | 21 |
16 bool ReadRegistryStringValue(RegKey* key, const string16& name, | 22 bool ReadRegistryStringValue(RegKey* key, const string16& name, |
17 string16* result) { | 23 string16* result) { |
18 DWORD value_size = 0; | 24 DWORD value_size = 0; |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 ERROR_SUCCESS) { | 150 ERROR_SUCCESS) { |
145 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) { | 151 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) { |
146 *result = value; | 152 *result = value; |
147 return true; | 153 return true; |
148 } | 154 } |
149 } | 155 } |
150 return false; | 156 return false; |
151 } | 157 } |
152 | 158 |
153 } // namespace policy | 159 } // namespace policy |
OLD | NEW |