Make updatedMillis a private field
Test: make Bug: 122677682 Change-Id: I54804d589994b01ac358ac5a9d55672ee7339771
This commit is contained in:
@@ -360,7 +360,7 @@ public class PackageInstallerService extends IPackageInstaller.Stub implements
|
||||
|
||||
final long age = System.currentTimeMillis() - session.createdMillis;
|
||||
final long timeSinceUpdate =
|
||||
System.currentTimeMillis() - session.updatedMillis;
|
||||
System.currentTimeMillis() - session.getUpdatedMillis();
|
||||
final boolean valid;
|
||||
if (session.isStaged()) {
|
||||
if (timeSinceUpdate >= MAX_TIME_SINCE_UPDATE_MILLIS
|
||||
|
||||
@@ -202,7 +202,7 @@ public class PackageInstallerSession extends IPackageInstallerSession.Stub {
|
||||
|
||||
/** Timestamp of the last time this session changed state */
|
||||
@GuardedBy("mLock")
|
||||
long updatedMillis;
|
||||
private long updatedMillis;
|
||||
|
||||
/** Uid of the creator of this session. */
|
||||
private final int mOriginalInstallerUid;
|
||||
@@ -1740,6 +1740,15 @@ public class PackageInstallerSession extends IPackageInstallerSession.Stub {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the timestamp of when this session last changed state
|
||||
*/
|
||||
public long getUpdatedMillis() {
|
||||
synchronized (mLock) {
|
||||
return updatedMillis;
|
||||
}
|
||||
}
|
||||
|
||||
String getInstallerPackageName() {
|
||||
synchronized (mLock) {
|
||||
return mInstallerPackageName;
|
||||
|
||||
Reference in New Issue
Block a user