In line with my earlier publish, and a few analysis on-line, I discovered that the sytem may be taking part in the music even after the service’s
onDestroy was referred to as as a result of it was holding on to some sources just like the
MediaPlayer, so I made a decision to really kill the method as a substitute of calling the
stopSelf, as a result of they merely usually are not working. Nonetheless, I synced all the applying states and referred to as
System.exit(0) and it kills the foreground course of in addition to the exercise as meant.
The one little bit of confusion I had is that if
System.exit(0) killed the method and likewise freed the app sources? That’s, does it launch each little bit of useful resource held by the app? I’m nervous about it as a result of I needn’t name
stopForeground() and different related cleanup strategies, only one
System.exit() does the trick.
It is okay to name this for my app, as a result of it triggers the behaviour I intend, however, I’m wondering if its okay for the android system, as a result of lingering recollections can be a foul factor. Thanks upfront, any perception can be useful.