summaryrefslogtreecommitdiff
path: root/packages/SettingsLib/src/com/android/settingslib/HelpUtils.java
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2013-09-20 09:32:11 -0700
committerDianne Hackborn <hackbod@google.com>2017-12-04 13:02:10 -0800
commit3accca05ddcad9d0b1b313eae49f273e39121d3c (patch)
tree7aca880abfecad17d7e3e1ad82e7891e480078a3 /packages/SettingsLib/src/com/android/settingslib/HelpUtils.java
parentdc3a8c7f84bf3673e184ce4acc592a1df9402746 (diff)
Add major version code to platform.
It turns the version code into almost a 64-bit integer, with the new major part being the upper 32 bits. The only tricky part about this is the backup manager, since it stored 32-bit version codes in its backup data sets. This is dealt with by, when the major version code is not 0, writing MIN_INT as the version code and following that by the full long version code, which we can detect when reading. Note that this makes backup sets containing apps with major version codes incompatible with older versions of the platform. Bug: 64459786 Test: Added in Change-Id: Iab8a682b62103babd6c16a56b8dc1e97d7078658 Change-Id: Ibfffe235bbfcf358b3741abd3f7197fdb063d3f3
Diffstat (limited to 'packages/SettingsLib/src/com/android/settingslib/HelpUtils.java')
-rw-r--r--packages/SettingsLib/src/com/android/settingslib/HelpUtils.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/SettingsLib/src/com/android/settingslib/HelpUtils.java b/packages/SettingsLib/src/com/android/settingslib/HelpUtils.java
index 2c2641079953..8055caaad536 100644
--- a/packages/SettingsLib/src/com/android/settingslib/HelpUtils.java
+++ b/packages/SettingsLib/src/com/android/settingslib/HelpUtils.java
@@ -227,7 +227,7 @@ public class HelpUtils {
// cache the version code
PackageInfo info = context.getPackageManager().getPackageInfo(
context.getPackageName(), 0);
- sCachedVersionCode = Integer.toString(info.versionCode);
+ sCachedVersionCode = Long.toString(info.getLongVersionCode());
// append the version code to the uri
builder.appendQueryParameter(PARAM_VERSION, sCachedVersionCode);