libbinder_ndk: association: rem heap allocs
libbinder_ndk, in the implementation of AIBinder_associateClass made
copies of and converted both IBinder and AIBinder_Class interface
descriptors to String8, even though they are already String16.
Bug: N/A
Test: atest aidl_integration_test
Change-Id: I99a5ed1dd06d32bfd28821a16792f37163b5179d
diff --git a/libs/binder/ndk/ibinder_internal.h b/libs/binder/ndk/ibinder_internal.h
index f4e2704..f601127 100644
--- a/libs/binder/ndk/ibinder_internal.h
+++ b/libs/binder/ndk/ibinder_internal.h
@@ -54,7 +54,7 @@
private:
std::optional<bool> associateClassInternal(const AIBinder_Class* clazz,
- const ::android::String8& newDescriptor, bool set);
+ const ::android::String16& newDescriptor, bool set);
// AIBinder instance is instance of this class for a local object. In order to transact on a
// remote object, this also must be set for simplicity (although right now, only the