hive365 / BugReports

0 stars 0 forks source link

Possible memory leak #11

Closed sleepy-evelyn closed 3 years ago

sleepy-evelyn commented 3 years ago

Stacktrace from leakcanary

D/LeakCanary: ​
    ====================================
    HEAP ANALYSIS RESULT
    ====================================
    1 APPLICATION LEAKS

    References underlined with "~~~" are likely causes.
    Learn more at https://squ.re/leaks.

    574 bytes retained by leaking objects
    Signature: 6491376cfe66b1cac0d47b3ae180fd902719aa5
    ┬───
    │ GC Root: Global variable in native code
    │
    ├─ android.app.job.JobService$1 instance
    │    Leaking: UNKNOWN
    │    Retaining 602 B in 13 objects
    │    Anonymous subclass of android.app.job.IJobService$Stub
    │    this$0 instance of com.google.android.datatransport.runtime.scheduling.jobscheduling.JobInfoSchedulerService
    │    ↓ JobService$1.this$0
    │                   ~~~~~~
    ╰→ com.google.android.datatransport.runtime.scheduling.jobscheduling.JobInfoSchedulerService instance
    ​     Leaking: YES (ObjectWatcher was watching this because com.google.android.datatransport.runtime.scheduling.
    ​     jobscheduling.JobInfoSchedulerService received Service#onDestroy() callback and Service not held by
    ​     ActivityThread)
    ​     Retaining 574 B in 12 objects
    ​     key = 80db5495-5bb9-45a6-9499-4a3eb81d6798
    ​     watchDurationMillis = 10279
    ​     retainedDurationMillis = 5277
    ​     mApplication instance of android.app.Application
    ​     mBase instance of android.app.ContextImpl
    ====================================
    0 LIBRARY LEAKS

    A Library Leak is a leak caused by a known bug in 3rd party code that you do not have control over.
    See https://square.github.io/leakcanary/fundamentals-how-leakcanary-works/#4-categorizing-leaks
    ====================================
    0 UNREACHABLE OBJECTS

    An unreachable object is still in memory but LeakCanary could not find a strong reference path
    from GC roots.
    ====================================
    METADATA

    Please include this in bug reports and Stack Overflow questions.

    Build.VERSION.SDK_INT: 22
    Build.MANUFACTURER: unknown
    LeakCanary version: 2.7
    App process name: com.hive365radio.android
    Stats: LruCache[maxSize=3000,hits=83,misses=85143,hitRate=0%]
    RandomAccess[bytes=6442761,reads=85143,travel=21365502202,range=16012686,size=18484402]
    Heap dump reason: user request
    Analysis duration: 40787 ms
    Heap dump file path: /storage/sdcard/Download/leakcanary-com.hive365radio.android/2021-05-16_16-18-40_945.hprof
    Heap dump timestamp: 1621178362761
    Heap dump duration: 587 ms
    ====================================
sleepy-evelyn commented 3 years ago

Fixed