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

Unified Diff: sandbox/tests/common/controller.cc

Issue 6816027: Make the windows_version.h functions threadsafe by using a singleton. Add accessors to the singl... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sandbox/src/service_resolver_unittest.cc ('k') | sandbox/tests/integration_tests/integration_tests.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sandbox/tests/common/controller.cc
===================================================================
--- sandbox/tests/common/controller.cc (revision 80824)
+++ sandbox/tests/common/controller.cc (working copy)
@@ -55,9 +55,10 @@
namespace sandbox {
std::wstring MakePathToSys(const wchar_t* name, bool is_obj_man_path) {
- if (base::win::GetWOW64Status() == base::win::WOW64_ENABLED)
- return MakePathToSysWow64(name, is_obj_man_path);
- return MakePathToSys32(name, is_obj_man_path);
+ return (base::win::OSInfo::GetInstance()->wow64_status() ==
+ base::win::OSInfo::WOW64_ENABLED) ?
+ MakePathToSysWow64(name, is_obj_man_path) :
+ MakePathToSys32(name, is_obj_man_path);
}
BrokerServices* GetBroker() {
@@ -138,7 +139,8 @@
if (!AddRule(TargetPolicy::SUBSYS_FILES, semantics, win32_path.c_str()))
return false;
- if (base::win::GetWOW64Status() != base::win::WOW64_ENABLED)
+ if (base::win::OSInfo::GetInstance()->wow64_status() !=
+ base::win::OSInfo::WOW64_ENABLED)
return true;
win32_path = MakePathToSysWow64(pattern, false);
« no previous file with comments | « sandbox/src/service_resolver_unittest.cc ('k') | sandbox/tests/integration_tests/integration_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698