WrappedApplicationKey: Remove superfluous branch in deserialization.

The metadata field is written unconditionally and will be represented at
least by a -1 if it is null.

Bug: 210655898
Test: N/A
Change-Id: Iad85dbec916a2d51523b81b594b66b9518811d27
This commit is contained in:
Janis Danisevskis
2022-03-24 15:28:15 -07:00
parent b8ebf69571
commit ffba3e7ac9

View File

@@ -167,10 +167,7 @@ public final class WrappedApplicationKey implements Parcelable {
protected WrappedApplicationKey(Parcel in) {
mAlias = in.readString();
mEncryptedKeyMaterial = in.createByteArray();
// Check if there is still data to be read.
if (in.dataAvail() > 0) {
mMetadata = in.createByteArray();
}
mMetadata = in.createByteArray();
}
@Override