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

Unified Diff: chrome/common/service_process_util_mac.mm

Issue 634583003: Simplify VersionInfo code, avoid hitting sandbox IPC constantly on Windows (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: linux include Created 6 years, 2 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 | « chrome/common/service_process_util.cc ('k') | chrome/common/service_process_util_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/service_process_util_mac.mm
diff --git a/chrome/common/service_process_util_mac.mm b/chrome/common/service_process_util_mac.mm
index d02362737a5feaf9732a484c42ebf8f4311433aa..a62c858d332842c3464aa0ccc5e4401f3db942af 100644
--- a/chrome/common/service_process_util_mac.mm
+++ b/chrome/common/service_process_util_mac.mm
@@ -209,24 +209,16 @@ bool CheckServiceProcessReady() {
ready = false;
} else {
chrome::VersionInfo version_info;
- if (!version_info.is_valid()) {
+ Version running_version(version_info.Version());
+ if (!running_version.IsValid()) {
// Our own version is invalid. This is an error case. Pretend that we
// are out of date.
NOTREACHED();
ready = true;
- }
- else {
- Version running_version(version_info.Version());
- if (!running_version.IsValid()) {
- // Our own version is invalid. This is an error case. Pretend that we
- // are out of date.
- NOTREACHED();
- ready = true;
- } else if (running_version.CompareTo(service_version) > 0) {
- ready = false;
- } else {
- ready = true;
- }
+ } else if (running_version.CompareTo(service_version) > 0) {
+ ready = false;
+ } else {
+ ready = true;
}
}
if (!ready) {
« no previous file with comments | « chrome/common/service_process_util.cc ('k') | chrome/common/service_process_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698