android内存使用率在没有泄漏的情况下不会降低
我刚开始用金丝雀。我使用此代码来避免片段中的内存泄漏android内存使用率在没有泄漏的情况下不会降低,android,memory-leaks,leakcanary,android-profiler,Android,Memory Leaks,Leakcanary,Android Profiler,我刚开始用金丝雀。我使用此代码来避免片段中的内存泄漏 public void onDestroyView() { super.onDestroyView(); view = null; imageView= null; recyclerView= null; progressBar = null; if (list != null) { list.clear(); } recyclerAdapter= null;
public void onDestroyView() {
super.onDestroyView();
view = null;
imageView= null;
recyclerView= null;
progressBar = null;
if (list != null) {
list.clear();
}
recyclerAdapter= null;
swipeRefreshLayout = null;
}
因此,当我将上述代码与LeakCanary一起使用时,我看到探查器中的内存使用正在减少(例如,它从120MB减少到80MB)。但当我移除LeakCanary(从gradle中)时,我看到内存使用并没有减少。它没有改变(仍然是120MB)。是虫子吗