Android-Image-Slider icon indicating copy to clipboard operation
Android-Image-Slider copied to clipboard

Leak Canary detects a memory leak across device configuration change. i.e reference to a destroyed activity SliderView.mContext is leaking

Open sleez007 opened this issue 5 years ago • 3 comments

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Add leakCanary to gradle build
  2. Install debug App on Phone
  3. Trigger a configuration change
  4. LeakCanary dumps a log for you

sleez007 avatar Mar 24 '20 11:03 sleez007

@sleez007 Did you find a solution for it?

GamalSebaee avatar May 18 '20 15:05 GamalSebaee

@GamalSebaee the solution i found for this was setting the adapter to null in onDestroyView

sleez007 avatar May 20 '20 11:05 sleez007

@sleez007 setting setAutoCycle(false) in onDestroy fix my issue

SanoopC avatar May 26 '20 15:05 SanoopC