diff --git a/core/java/android/app/compat/ChangeIdStateQuery.java b/core/java/android/app/compat/ChangeIdStateQuery.java index 91765f78a2b01..7598d6c90d3d8 100644 --- a/core/java/android/app/compat/ChangeIdStateQuery.java +++ b/core/java/android/app/compat/ChangeIdStateQuery.java @@ -85,6 +85,14 @@ final class ChangeIdStateQuery { @Override public int hashCode() { - return Objects.hash(type, changeId, packageName, uid, userId); + int result = 1; + result = 31 * result + type; + result = 31 * result + (int) (changeId ^ (changeId >>> 32)); + if (packageName != null) { + result = 31 * result + packageName.hashCode(); + } + result = 31 * result + uid; + result = 31 * result + userId; + return result; } }