[automerge] Fix NPE 2p: 18179a8762
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/17592146 Bug: 227342978 Change-Id: I6ea0f4792197af9fde542c7407b9549a2f3b48c1 Merged-In: Ia21323926bd9db1a6f05461904deb45b4c3dd0bc
This commit is contained in:
@@ -394,7 +394,10 @@ public class PackageInstallerService extends IPackageInstaller.Stub implements
|
||||
// Their staging dirs will be removed too
|
||||
PackageInstallerSession root = !session.hasParentSessionId()
|
||||
? session : mSessions.get(session.getParentSessionId());
|
||||
if (!root.isDestroyed()) {
|
||||
if (root == null) {
|
||||
Slog.e(TAG, "freeStageDirs: found an orphaned session: "
|
||||
+ session.sessionId + " parent=" + session.getParentSessionId());
|
||||
} else if (!root.isDestroyed()) {
|
||||
root.abandon();
|
||||
}
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user