diff options
author | 2021-04-02 02:52:46 +0000 | |
---|---|---|
committer | 2021-04-09 20:16:46 +0000 | |
commit | 1a3a8effca802995ece193b7d40cd80abba55798 (patch) | |
tree | 6d4d56881d48e2067459e26eb8d6f61a11ac7197 /libs/binder/Parcel.cpp | |
parent | 64eff6c18215bf4c70ce8b56d2c1304157260bec (diff) |
libbinder use stronger refbase semantics
As a larger example of how to use
ANDROID_UTILS_REF_BASE_DISABLE_IMPLICIT_CONSTRUCTION.
Bug: 184190315
Test: boot (relevant tests in TEST_MAPPING)
Change-Id: I88283543e1f63fd1010f9cd3f63baefec84e6a84
Diffstat (limited to 'libs/binder/Parcel.cpp')
-rw-r--r-- | libs/binder/Parcel.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libs/binder/Parcel.cpp b/libs/binder/Parcel.cpp index b1dddd14ec..98ca829031 100644 --- a/libs/binder/Parcel.cpp +++ b/libs/binder/Parcel.cpp @@ -293,7 +293,8 @@ status_t Parcel::unflattenBinder(sp<IBinder>* out) const if (flat) { switch (flat->hdr.type) { case BINDER_TYPE_BINDER: { - sp<IBinder> binder = reinterpret_cast<IBinder*>(flat->cookie); + sp<IBinder> binder = + sp<IBinder>::fromExisting(reinterpret_cast<IBinder*>(flat->cookie)); return finishUnflattenBinder(binder, out); } case BINDER_TYPE_HANDLE: { |