What is going on with the "Unexpected resume of <packagename> while already resumed" message on Android?
<p>Several of my Android applications show the following type message in the logcat output:</p>

<pre><code>I/UsageStats(   59): Unexpected resume of com.totsp.test while already resumed in com.totsp.test
</code></pre>

<p>In this case I created the default Hello World app by letting the ADT tool generate it, and it still gets this message. I am not doing anything special in <em>onCreate</em> and don't even have any other methods defined. </p>

<p>I realize this is an INFO level message, and it doesn't appear to hurt anything, but I was curious what was going on so I made a test application that keeps track of the <em>onResume</em> invocations. It is indeed re-resuming when this occurs. I'm wondering why this this occurs? While I haven't noticed a problem (other than these annoying log messages), it seems like it could be using more resources than necessary to do all this stuff an extra time.  </p>

<p>I have searched and read a similar question here on SO, and the answer there seems dubious to me: <a href="http://stackoverflow.com/questions/2606470/unexpected-resume-of-package-name-while-already-resumed-in-package-name-erro">http://stackoverflow.com/questions/2606470/unexpected-resume-of-package-name-while-already-resumed-in-package-name-erro</a>. Specifically, no, you don't want to use <em>android:configChanges="orientation"</em> because that is just subverting the orientation tear down/resume, rather than fixing it. Even the documentation notes "this attribute should be avoided and used only as a last-resort" (<a href="http://developer.android.com/intl/de/guide/topics/manifest/activity-element.html#config">http://developer.android.com/intl/de/guide/topics/manifest/activity-element.html#config</a>). </p>

<p>Also I have seen thread in the Android dev group where Mr. Murphy says the "unexpected resume" is "benign": <a href="http://groups.google.com/group/android-developers/browse_thread/thread/567410dbfcc163c2">http://groups.google.com/group/android-developers/browse_thread/thread/567410dbfcc163c2</a>. </p>

<p>I'll dig into the source when I get a chance, but I figured I would first just ask the all-knowing hivemind and see if someone already knows: why does this occur, and is it truly benign?  </p>
