Refactor getPackagesForSharedUid.
Replace gstSharedUserIdForPackage() and getPackagesForSharedUserId()
with a function to combine the two,
getSharedUserPackagesForPackage(). This satisfies all the existing use
cases with reasonably clean semantics, and avoids the need to
special-case the situation where the package doesn't have a shared
UID.
Clarify that the result is never null, and remove some redundant null
checks.
Fixes: 146418551
Test: atest PackageManagerTests
Change-Id: I8f34c9071434f908893437a5c6c89defaa5fd576
5 files changed