I uses YoutubeServie API to play youtube video in my Android application. However when I exit my activity, I found the below crash log showing, even my App still works.
Even if you do not manually register any receiver, an activity may register it to use it in some way on the current activity. I think you should need to call unregisterReceiver() method on onPause().
Please be aware that onDestroy() and onStop() are not guaranteed to be called. If onPause() will be called, then the Activity is no longer in the foreground.
OnStop():
Called when you are no longer visible to the user. You will next receive either onRestart(), onDestroy(), or nothing, depending on later user activity. Note that this method may never be called, in low memory situations where the system does not have enough memory to keep your activity's process running after its onPause() method is called.
For more information, here's the link: http://developer.android.com/reference/android/app/Activity.html#onStop%28%29
Fortunately, I also found some stackoverflow items that you can refer to:
I hope this will help.