Fix incorrect handling of pending activities

The full-screen activities in the SIM Toolkit application are expected
to keep staying in the screen even after TERMINAL RESPONSE is sent as
they might still be seen around the dialog launched by the next command.

StkAppService has a mechanism to keep such a "pending instance" and
finish it when the current session ends, but it cannot finish it
sometimes in the current implementation. If the current pending activity
is pushed out by the new one, the former one must be finished. It must
not have a reason to stay anymore at that time.

Bug: 38330809

Change-Id: Ib0399d0101c8555d6d0a3426df28db49349fef8e
2 files changed