Fix NullPointerException on a null Application object

When process attached, the app process was set to active
earlier than binding to client application. So, it was
possible to start activities or notify client to handle
configuration changes before binding applications.

Bug: 119621502
Test: adb shell monkey 100000
Change-Id: I969705f01ae00ae41e9df85567484b4ae1363d4f
1 file changed