Reduce framework-connectivity footprint
Cleanup framework-connectivity to reduce its memory and storage usage: - Build libframework-connectivity-jni using standard C and removing dependencies on libc++. This saves about 100kB of storage (40+60kB on the 32+64 bit variants). - Remove dependency on protobuffer libraries, as their usage has been removed. This saves about 15kB of storage. From local measurements, the reduced code size also improves memory usage. This also removes a jarjar workaround for net-utils-device-common, as the library is no longer used either. Bug: 184111895 Test: device boots, connectivity working Change-Id: Ibfbd0fe1098293812ae24812621752a7a44f9130
This commit is contained in:
@@ -655,25 +655,6 @@ public class NetworkRequest implements Parcelable {
|
||||
", " + networkCapabilities.toString() + " ]";
|
||||
}
|
||||
|
||||
private int typeToProtoEnum(Type t) {
|
||||
switch (t) {
|
||||
case NONE:
|
||||
return NetworkRequestProto.TYPE_NONE;
|
||||
case LISTEN:
|
||||
return NetworkRequestProto.TYPE_LISTEN;
|
||||
case TRACK_DEFAULT:
|
||||
return NetworkRequestProto.TYPE_TRACK_DEFAULT;
|
||||
case REQUEST:
|
||||
return NetworkRequestProto.TYPE_REQUEST;
|
||||
case BACKGROUND_REQUEST:
|
||||
return NetworkRequestProto.TYPE_BACKGROUND_REQUEST;
|
||||
case TRACK_SYSTEM_DEFAULT:
|
||||
return NetworkRequestProto.TYPE_TRACK_SYSTEM_DEFAULT;
|
||||
default:
|
||||
return NetworkRequestProto.TYPE_UNKNOWN;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean equals(@Nullable Object obj) {
|
||||
if (obj instanceof NetworkRequest == false) return false;
|
||||
NetworkRequest that = (NetworkRequest)obj;
|
||||
|
||||
Reference in New Issue
Block a user