Skip to content
This repository has been archived by the owner on Dec 18, 2023. It is now read-only.

Problems about JSONDownloadTask #49

Open
pangeneral opened this issue Aug 13, 2019 · 0 comments
Open

Problems about JSONDownloadTask #49

pangeneral opened this issue Aug 13, 2019 · 0 comments

Comments

@pangeneral
Copy link

pangeneral commented Aug 13, 2019

The inner class JSONDownloadTask defined in

  1. be.brunoparmentier.openbikesharing.app.activities.BikeNetworksListActivity
  2. be.brunoparmentier.openbikesharing.app.activities.StationsListActivity
    holds strong reference to the Activity which can lead to memory leak.
    I think we should change JSONDownloadTask to an static class or outter class.

Besides, the instance of JSONDownloadTask is not cancelled, which can lead to result loss. I think the instance of JSONDownloadTask should be cancelled before the Activity is destroyed.

@pangeneral pangeneral changed the title Memory leak caused by JSONDownloadTask Problems about JSONDownloadTask Aug 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant