Merge "Finish pending activity or dialog when the current session ends"
am: ce9d5d6555

Change-Id: I8d797d11a285ab2b51d699bac791a84fb9af17eb