* Bundle supports types char, char[], short[], float[] which were
falling back to serializable handling in Parcel because readValue()
didn't have specific support for those types. Adding support in Parcel
to avoid the need for length-prefixing and to improve performance.
Curiously some of those had read/write methods already.
* Updated Bundle to just pull the types above from the map since those
won't be lazy values anymore.
* We were missing a few custom type containers in our list of
length-prefixed types and we were listing Bundle unnecessarily as
length-prefixed since Bundle itself is already length-prefixed and
copies the correspondent section of the parcel internally.
Test: atest -d android.os.cts.ParcelTest android.os.cts.BundleTest android.os.BundleTest android.os.ParcelTest
Bug: 195622897
Change-Id: I1e15d59d883311685ffa32ece1f5a00e01bf6aea
This target produces nearly identical contents to the build target
framework-doc-stubs (the only diffs are in whitespace). Using this
module in the SDK zip will allow changing the inputs of
framework-doc-stubs to java sources that don't have all the annotations
(the jar stubs).
Bug: 187397779
Test: m sdk-annotations.zip and diff with framework-doc-stubs zip
Change-Id: Id163473c455f25c5f31c965d907c0c3b0e7755fc
Description:
Added replacements of `readList`, `readParcelable` and
`readParcelableCreator` APIs.
To avoid unexpected types of objects being unparcelled,
ideally clients would use the readTypedXXX() methods that
take the parcelable creator. However, this won’t be an option
for use cases involving deserializing children objects
inherited from non-final parcelable or serializable objects.
Currently out of ~4k parcelable classes, only ~1.5k
are marked as “final” in the platform. Hence it would be
necessary to introduce new replacements that take
an extra Class<T> parameter and before deserializing
we check that the class written on the wire is the
same or a descendant from the one provided as argument.
Doing so could enhance the security of Parcel deserialization,
More details can be found at go/safer-parcel.
Test: atest -d android.os.cts.ParcelTest
Bug: 195622897
Change-Id: Ie9a4cb4c3d6f1805b14df7b703aef43e2993d459
So that the API more closely matches intended usage, as requested.
Bug: 175814583
Test: aidl_integration_test
Change-Id: I2fb5f2d5059d7f9cd9e034a4d0d2e7aa63692067
Log mismatches as wtf to be able track those. Also added unit tests
around kindofEquals() and r/w mismatches.
Test: atest -d android.os.cts.ParcelTest android.os.cts.BundleTest android.os.BundleTest android.os.ParcelTest
Bug: 195622897
Change-Id: I361dd144b23975eedc8b19ed65457a1c5405936e
Ensures that all queued actions on local devices are started after
boot. Previously, an unstarted SendKeyAction could stick around after
boot, blocking any future SendKeyAction from being created.
Unit tests omitted because of AOSP incompatibilities.
Bug: 193188675
Test: atest HdmiControlServiceTest#normalBoot_queuedActionsStartedAfterBoot
manual test: spam volume up on boot with IR volume control enabled
Change-Id: I0050ca927bdba939b0b0030a6aa2f6235b11ff5c
Merged-In: I0050ca927bdba939b0b0030a6aa2f6235b11ff5c
(cherry picked from commit 22dc89a89f)
Ensures that all queued actions on local devices are started after
boot. Previously, an unstarted SendKeyAction could stick around after
boot, blocking any future SendKeyAction from being created.
Bug: 193188675
Test: atest HdmiControlServiceTest#normalBoot_queuedActionsStartedAfterBoot
manual test: spam volume up on boot with IR volume control enabled
Change-Id: I0050ca927bdba939b0b0030a6aa2f6235b11ff5c
Merged-In: I0050ca927bdba939b0b0030a6aa2f6235b11ff5c
(cherry picked from commit 22dc89a89f)
(cherry picked from commit 66b6a8cc17d3c2f4d7d3a09369f7538633c43259)