summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorjuwei <juwei@codeaurora.org>2016-12-30 18:15:33 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2017-01-05 17:28:56 -0800
commitef0bdb7d10a0f0b6c0d8e022e6b557030dcfda3b (patch)
tree28fd2efd6bf80f804b5bb304396440e10be2f2e4 /src
parent15f6d966c807c371a12f68bf9f5f4e7447a9ba8e (diff)
downloadandroid_packages_apps_Snap-ef0bdb7d10a0f0b6c0d8e022e6b557030dcfda3b.tar.gz
android_packages_apps_Snap-ef0bdb7d10a0f0b6c0d8e022e6b557030dcfda3b.tar.bz2
android_packages_apps_Snap-ef0bdb7d10a0f0b6c0d8e022e6b557030dcfda3b.zip
SnapdragonCamera: Fix crash during UI stress test
CaptureModule and CaptureUI have register listeners in SettingsManager, but forget unregiseter when UI destroy. This makes the too many RenderNode objects exist and never GC. At last, the weak reference of RenderNode at native layer exceed the 51200 limitation and crash. Unregister the listener of SettingsManager will fix it. Change-Id: I881b47f8f062c366e028db59a8cf6983c1d99f5a CRs-Fixed: 1103907
Diffstat (limited to 'src')
-rw-r--r--src/com/android/camera/CaptureModule.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/com/android/camera/CaptureModule.java b/src/com/android/camera/CaptureModule.java
index 26613786f..4b71f9b09 100644
--- a/src/com/android/camera/CaptureModule.java
+++ b/src/com/android/camera/CaptureModule.java
@@ -2358,6 +2358,8 @@ public class CaptureModule implements CameraModule, PhotoController,
if(mFrameProcessor != null){
mFrameProcessor.onDestory();
}
+ mSettingsManager.unregisterListener(this);
+ mSettingsManager.unregisterListener(mUI);
}
@Override