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

Unified Diff: chrome/installer/util/install_util.cc

Issue 6713107: Make the windows_version.h functions threadsafe by using a singleton. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 9 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
Index: chrome/installer/util/install_util.cc
===================================================================
--- chrome/installer/util/install_util.cc (revision 80528)
+++ chrome/installer/util/install_util.cc (working copy)
@@ -136,15 +136,14 @@
}
bool InstallUtil::IsOSSupported() {
- int major, minor;
base::win::Version version = base::win::GetVersion();
- base::win::GetServicePackLevel(&major, &minor);
+ const int* service_pack = base::win::OSInfo::GetInstance()->service_pack();
// We do not support Win2K or older, or XP without service pack 2.
VLOG(1) << "Windows Version: " << version
- << ", Service Pack: " << major << "." << minor;
+ << ", Service Pack: " << service_pack[0] << "." << service_pack[1];
return (version > base::win::VERSION_XP) ||
- (version == base::win::VERSION_XP && major >= 2);
+ (version == base::win::VERSION_XP && service_pack[0] >= 2);
}
void InstallUtil::WriteInstallerResult(bool system_install,

Powered by Google App Engine
This is Rietveld 408576698