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 "base/string_number_conversions.h" | 7 #include "base/string_number_conversions.h" |
8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
9 #include "base/win/registry.h" | 9 #include "base/win/registry.h" |
10 #include "chrome/common/policy_constants.h" | 10 #include "policy/policy_constants.h" |
11 | 11 |
12 using base::win::RegKey; | 12 using base::win::RegKey; |
13 | 13 |
14 namespace { | 14 namespace { |
15 | 15 |
16 bool ReadRegistryStringValue(RegKey* key, const string16& name, | 16 bool ReadRegistryStringValue(RegKey* key, const string16& name, |
17 string16* result) { | 17 string16* result) { |
18 DWORD value_size = 0; | 18 DWORD value_size = 0; |
19 DWORD key_type = 0; | 19 DWORD key_type = 0; |
20 scoped_array<uint8> buffer; | 20 scoped_array<uint8> buffer; |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 ERROR_SUCCESS) { | 144 ERROR_SUCCESS) { |
145 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) { | 145 if (policy_key.ReadValueDW(value_name.c_str(), &value) == ERROR_SUCCESS) { |
146 *result = value; | 146 *result = value; |
147 return true; | 147 return true; |
148 } | 148 } |
149 } | 149 } |
150 return false; | 150 return false; |
151 } | 151 } |
152 | 152 |
153 } // namespace policy | 153 } // namespace policy |
OLD | NEW |