Android zzat.zzda中的泄漏用leal canary追踪
我的应用程序有漏洞,我不知道它来自哪里。我正在使用泄漏金丝雀追踪泄漏,但仍然无法查明确切原因 任何新的建议如何处理这个问题将不胜感激 这是泄漏金丝雀的泄漏:Android zzat.zzda中的泄漏用leal canary追踪,android,flutter,memory-leaks,leakcanary,Android,Flutter,Memory Leaks,Leakcanary,我的应用程序有漏洞,我不知道它来自哪里。我正在使用泄漏金丝雀追踪泄漏,但仍然无法查明确切原因 任何新的建议如何处理这个问题将不胜感激 这是泄漏金丝雀的泄漏: ┬─── │ GC Root: Global variable in native code │ ├─ com.google.android.gms.internal.location.zzat instance │ Leaking: UNKNOWN │ Retaining 748 B in 28 objects │ ↓
┬───
│ GC Root: Global variable in native code
│
├─ com.google.android.gms.internal.location.zzat instance
│ Leaking: UNKNOWN
│ Retaining 748 B in 28 objects
│ ↓ zzat.zzda
│ ~~~~
├─ com.google.android.gms.common.api.internal.ListenerHolder instance
│ Leaking: UNKNOWN
│ Retaining 655 B in 26 objects
│ ↓ ListenerHolder.zajl
│ ~~~~
├─ com.google.android.gms.common.api.internal.ListenerHolder$ListenerKey
│ instance
│ Leaking: UNKNOWN
│ Retaining 603 B in 24 objects
│ ↓ ListenerHolder$ListenerKey.zajk
│ ~~~~
├─ com.baseflow.geolocator.location.FusedLocationClient$1 instance
│ Leaking: UNKNOWN
│ Retaining 555 B in 22 objects
│ Anonymous subclass of com.google.android.gms.location.LocationCallback
│ val$context instance of com.example.app.Application
│ ↓ FusedLocationClient$1.this$0
│ ~~~~~~
├─ com.baseflow.geolocator.location.FusedLocationClient instance
│ Leaking: UNKNOWN
│ Retaining 539 B in 21 objects
│ activity instance of com.example.app.MainActivity with mDestroyed = true
│ context instance of com.example.app.Application
│ ↓ FusedLocationClient.activity
│ ~~~~~~~~
╰→ com.example.app.MainActivity instance
Leaking: YES (ObjectWatcher was watching this because com.example.app.
MainActivity received Activity#onDestroy() callback and
Activity#mDestroyed is true)
Retaining 3.5 kB in 95 objects
key = a383df6c-fd8f-4cf8-93a0-bb6278015791
watchDurationMillis = 5246
retainedDurationMillis = 244
mApplication instance of com.example.app.Application
mBase instance of android.app.ContextImpl
也许我迟到了,但是如果你仍然面临这个问题,你能分享一下你是如何使用FusedLocationClient的吗?可能没有删除位置更新,或者某个匿名类正在捕获您的活动实例。