Connect to activity manager as root.

Before dropping root privileges, connect to the activity manager.
Also, only connect to the activity manager if this is a crash.

Bug: 28210681
(cherry picked from commit 0fc89f34b99f20f0ebc0111df74490f4ebd44076)

Change-Id: Id25b92e550d71ffe1b9eafe43976ef514a83714b
3 files changed