Correct checking whether activity name contains package.

There are cases where the activity name is null, which leads to a NPE
when checking for the presence of the package. This CL adds the
additional null pointer check.

Change-Id: I5c44eaaa9337a4012ce3be4f50726b035f1f4162
Fixes: 38384921
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test CtsServicesHostTestCases android.server.cts.ActivityManagerDockedStackTests#testLaunchToSide
(cherry picked from commit 637b1d5812753496fdc95378c3eae32e4768e221)
1 file changed