OLD | NEW |
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 "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/files/file_path.h" | 6 #include "base/files/file_path.h" |
7 #include "base/metrics/field_trial.h" | 7 #include "base/metrics/field_trial.h" |
8 #include "base/metrics/histogram.h" | 8 #include "base/metrics/histogram.h" |
9 #include "base/metrics/sparse_histogram.h" | 9 #include "base/metrics/sparse_histogram.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
211 | 211 |
212 bool GetLoadedBlacklistedModules(std::vector<base::string16>* module_names) { | 212 bool GetLoadedBlacklistedModules(std::vector<base::string16>* module_names) { |
213 DCHECK(module_names); | 213 DCHECK(module_names); |
214 | 214 |
215 std::set<ModuleInfo> module_info_set; | 215 std::set<ModuleInfo> module_info_set; |
216 if (!GetLoadedModules(&module_info_set)) | 216 if (!GetLoadedModules(&module_info_set)) |
217 return false; | 217 return false; |
218 | 218 |
219 std::set<ModuleInfo>::const_iterator module_iter(module_info_set.begin()); | 219 std::set<ModuleInfo>::const_iterator module_iter(module_info_set.begin()); |
220 for (; module_iter != module_info_set.end(); ++module_iter) { | 220 for (; module_iter != module_info_set.end(); ++module_iter) { |
221 base::string16 module_file_name(StringToLowerASCII( | 221 base::string16 module_file_name(base::StringToLowerASCII( |
222 base::FilePath(module_iter->name).BaseName().value())); | 222 base::FilePath(module_iter->name).BaseName().value())); |
223 if (blacklist::GetBlacklistIndex(module_file_name.c_str()) != -1) { | 223 if (blacklist::GetBlacklistIndex(module_file_name.c_str()) != -1) { |
224 module_names->push_back(module_iter->name); | 224 module_names->push_back(module_iter->name); |
225 } | 225 } |
226 } | 226 } |
227 | 227 |
228 return true; | 228 return true; |
229 } | 229 } |
OLD | NEW |