summaryrefslogtreecommitdiffstats
path: root/chrome/installer
diff options
context:
space:
mode:
authormark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-24 02:19:17 +0000
committermark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-24 02:19:17 +0000
commit095e969915bba8b3b4d098864ec3aefe501cd597 (patch)
tree4b8a19f5fafcc4055f7deee9d98f2d673f93c2d5 /chrome/installer
parent12d36ad61b88473f72773aa95a4eaa09336e6b4b (diff)
downloadchromium_src-095e969915bba8b3b4d098864ec3aefe501cd597.zip
chromium_src-095e969915bba8b3b4d098864ec3aefe501cd597.tar.gz
chromium_src-095e969915bba8b3b4d098864ec3aefe501cd597.tar.bz2
Use --version-path and --version-key when available during an update, if
Keystone 1.0.9.2318 or later is present. Providing this data to Keystone will cause it to check the application's Info.plist to determine the installed version, rather than using the version embedded within the ticket. The version in the ticket can become stale in some rare situations through innocent user action. This allows a user to replace Chrome with an earlier version (perhaps on another channel) and not get "stuck" without autoupdates until that channel catches up with the version listed in the ticket. (b/2506062) This also prevents Keystone from believing an update is still available if Chrome is updated but not restarted and the user subsequently promotes Chrome's user ticket to a system ticket from within Chrome. (crbug.com/38696) BUG=38696, 83082 TEST=none Review URL: http://codereview.chromium.org/7029034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86388 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/installer')
-rwxr-xr-xchrome/installer/mac/keystone_install.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/chrome/installer/mac/keystone_install.sh b/chrome/installer/mac/keystone_install.sh
index c7cc570..24609d2 100755
--- a/chrome/installer/mac/keystone_install.sh
+++ b/chrome/installer/mac/keystone_install.sh
@@ -379,6 +379,15 @@ ksadmin_supports_brandpath_brandkey() {
# return value.
}
+# Returns 0 (true) if ksadmin supports --version-path and --version-key.
+ksadmin_supports_versionpath_versionkey() {
+ # --version-path and --version-key were introduced in Keystone 1.0.9.2318.
+ is_ksadmin_version_ge 1.0.9.2318
+
+ # The return value of is_ksadmin_version_ge is used as this function's
+ # return value.
+}
+
usage() {
echo "usage: ${ME} update_dmg_mount_point" >& 2
}
@@ -1076,6 +1085,13 @@ main() {
)
fi
+ if ksadmin_supports_versionpath_versionkey; then
+ ksadmin_args+=(
+ --version-path "${installed_app_plist_path}"
+ --version-key "${KS_VERSION_KEY}"
+ )
+ fi
+
note "ksadmin_args = ${ksadmin_args[*]}"
if ! ksadmin "${ksadmin_args[@]}"; then