Only require that system UIDs tag their sockets.

Apps with a normal UID are typically isolated enough to not require
socket tagging; we're mostly interested in tracking down internal
UIDs that have lots of code sharing the same UID.

Also fix up everyone doing manual string checks of Build.TYPE, since
we now have first-class fields for those.

Bug: 38126076
Test: builds, boots
Change-Id: I3a40348196bd8459289f2b9355d9783a07f1e7dd
This commit is contained in:
Jeff Sharkey
2017-06-27 11:01:36 -06:00
parent 8af5ad1575
commit 65501f8094

View File

@@ -157,7 +157,7 @@ public class NetworkIdentity implements Comparable<NetworkIdentity> {
* Scrub given IMSI on production builds.
*/
public static String scrubSubscriberId(String subscriberId) {
if ("eng".equals(Build.TYPE)) {
if (Build.IS_ENG) {
return subscriberId;
} else if (subscriberId != null) {
// TODO: parse this as MCC+MNC instead of hard-coding