Skip to content

Commit 6eef0ca

Browse files
Dianne HackbornAndroid (Google) Code Review
authored andcommitted
Merge "frameworks/base: Fix to release references in ActivityManagerService" into gingerbread
2 parents c6f2b3b + a207ce2 commit 6eef0ca

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

services/java/com/android/server/am/ActivityManagerService.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9093,6 +9093,14 @@ private final void bringDownServiceLocked(ServiceRecord r, boolean force) {
90939093
if (DEBUG_SERVICE) Slog.v(
90949094
TAG, "Removed service that is not running: " + r);
90959095
}
9096+
9097+
if (r.bindings.size() > 0) {
9098+
r.bindings.clear();
9099+
}
9100+
9101+
if (r.restarter instanceof ServiceRestarter) {
9102+
((ServiceRestarter)r.restarter).setService(null);
9103+
}
90969104
}
90979105

90989106
ComponentName startServiceLocked(IApplicationThread caller,

0 commit comments

Comments
 (0)