Merge "Revert "Revert "Migrate unsafe parcel APIs in framework-minus-apex"""
This commit is contained in:
committed by
Android (Google) Code Review
commit
27c23a42fa
@@ -75,7 +75,7 @@ public final class DataUsageRequest implements Parcelable {
|
||||
@Override
|
||||
public DataUsageRequest createFromParcel(Parcel in) {
|
||||
int requestId = in.readInt();
|
||||
NetworkTemplate template = in.readParcelable(null);
|
||||
NetworkTemplate template = in.readParcelable(null, android.net.NetworkTemplate.class);
|
||||
long thresholdInBytes = in.readLong();
|
||||
DataUsageRequest result = new DataUsageRequest(requestId, template,
|
||||
thresholdInBytes);
|
||||
|
||||
@@ -267,14 +267,14 @@ public final class IpSecConfig implements Parcelable {
|
||||
mMode = in.readInt();
|
||||
mSourceAddress = in.readString();
|
||||
mDestinationAddress = in.readString();
|
||||
mNetwork = (Network) in.readParcelable(Network.class.getClassLoader());
|
||||
mNetwork = (Network) in.readParcelable(Network.class.getClassLoader(), android.net.Network.class);
|
||||
mSpiResourceId = in.readInt();
|
||||
mEncryption =
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader());
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader(), android.net.IpSecAlgorithm.class);
|
||||
mAuthentication =
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader());
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader(), android.net.IpSecAlgorithm.class);
|
||||
mAuthenticatedEncryption =
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader());
|
||||
(IpSecAlgorithm) in.readParcelable(IpSecAlgorithm.class.getClassLoader(), android.net.IpSecAlgorithm.class);
|
||||
mEncapType = in.readInt();
|
||||
mEncapSocketResourceId = in.readInt();
|
||||
mEncapRemotePort = in.readInt();
|
||||
|
||||
@@ -81,7 +81,7 @@ public final class IpSecUdpEncapResponse implements Parcelable {
|
||||
status = in.readInt();
|
||||
resourceId = in.readInt();
|
||||
port = in.readInt();
|
||||
fileDescriptor = in.readParcelable(ParcelFileDescriptor.class.getClassLoader());
|
||||
fileDescriptor = in.readParcelable(ParcelFileDescriptor.class.getClassLoader(), android.os.ParcelFileDescriptor.class);
|
||||
}
|
||||
|
||||
@android.annotation.NonNull
|
||||
|
||||
@@ -73,9 +73,9 @@ public final class NetworkStateSnapshot implements Parcelable {
|
||||
|
||||
/** @hide */
|
||||
public NetworkStateSnapshot(@NonNull Parcel in) {
|
||||
mNetwork = in.readParcelable(null);
|
||||
mNetworkCapabilities = in.readParcelable(null);
|
||||
mLinkProperties = in.readParcelable(null);
|
||||
mNetwork = in.readParcelable(null, android.net.Network.class);
|
||||
mNetworkCapabilities = in.readParcelable(null, android.net.NetworkCapabilities.class);
|
||||
mLinkProperties = in.readParcelable(null, android.net.LinkProperties.class);
|
||||
mSubscriberId = in.readString();
|
||||
mLegacyType = in.readInt();
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ public final class UnderlyingNetworkInfo implements Parcelable {
|
||||
mOwnerUid = in.readInt();
|
||||
mIface = in.readString();
|
||||
List<String> underlyingIfaces = new ArrayList<>();
|
||||
in.readList(underlyingIfaces, null /*classLoader*/);
|
||||
in.readList(underlyingIfaces, null /*classLoader*/, java.lang.String.class);
|
||||
mUnderlyingIfaces = Collections.unmodifiableList(underlyingIfaces);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user