summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--base/file_version_info_mac.mm9
1 files changed, 6 insertions, 3 deletions
diff --git a/base/file_version_info_mac.mm b/base/file_version_info_mac.mm
index 3b5a8ba..8542b19 100644
--- a/base/file_version_info_mac.mm
+++ b/base/file_version_info_mac.mm
@@ -62,10 +62,13 @@ base::string16 FileVersionInfoMac::legal_copyright() {
base::string16 FileVersionInfoMac::product_version() {
// On OS X, CFBundleVersion is used by LaunchServices, and must follow
// specific formatting rules, so the four-part Chrome version is in
- // CFBundleShortVersionString. On iOS, however, CFBundleVersion can be the
- // full version, but CFBundleShortVersionString has a policy-enfoced limit
- // of three version components.
+ // CFBundleShortVersionString. On iOS, both have a policy-enfoced limit
+ // of three version components, so the full version is stored in a custom
+ // key (CrBundleVersion) falling back to CFBundleVersion if not present.
#if defined(OS_IOS)
+ base::string16 version(GetString16Value(CFSTR("CrBundleVersion")));
+ if (version.length() > 0)
+ return version;
return GetString16Value(CFSTR("CFBundleVersion"));
#else
return GetString16Value(CFSTR("CFBundleShortVersionString"));