Loading libs/binder/parcel_fuzzer/binder.cpp +9 −2 Original line number Diff line number Diff line Loading @@ -143,6 +143,13 @@ std::vector<ParcelRead<::android::Parcel>> BINDER_PARCEL_READ_FUNCTIONS { FUZZ_LOG() << "read c-str: " << (str ? str : "<empty string>"); }, PARCEL_READ_OPT_STATUS(android::String8, readString8), [] (const ::android::Parcel& p, uint8_t /*data*/) { FUZZ_LOG() << "about to readString8Inplace"; size_t outLen = 0; const char* str = p.readString8Inplace(&outLen); std::string bytes = hexString(str, sizeof(char) * (outLen + 1)); FUZZ_LOG() << "readString8Inplace: " << bytes << " size: " << outLen; }, PARCEL_READ_OPT_STATUS(android::String16, readString16), PARCEL_READ_WITH_STATUS(std::unique_ptr<android::String16>, readString16), PARCEL_READ_WITH_STATUS(std::optional<android::String16>, readString16), Loading @@ -150,8 +157,8 @@ std::vector<ParcelRead<::android::Parcel>> BINDER_PARCEL_READ_FUNCTIONS { FUZZ_LOG() << "about to readString16Inplace"; size_t outLen = 0; const char16_t* str = p.readString16Inplace(&outLen); FUZZ_LOG() << "readString16Inplace: " << hexString(str, sizeof(char16_t) * outLen) << " size: " << outLen; std::string bytes = hexString(str, sizeof(char16_t) * (outLen + 1)); FUZZ_LOG() << "readString16Inplace: " << bytes << " size: " << outLen; }, PARCEL_READ_WITH_STATUS(android::sp<android::IBinder>, readStrongBinder), PARCEL_READ_WITH_STATUS(android::sp<android::IBinder>, readNullableStrongBinder), Loading Loading
libs/binder/parcel_fuzzer/binder.cpp +9 −2 Original line number Diff line number Diff line Loading @@ -143,6 +143,13 @@ std::vector<ParcelRead<::android::Parcel>> BINDER_PARCEL_READ_FUNCTIONS { FUZZ_LOG() << "read c-str: " << (str ? str : "<empty string>"); }, PARCEL_READ_OPT_STATUS(android::String8, readString8), [] (const ::android::Parcel& p, uint8_t /*data*/) { FUZZ_LOG() << "about to readString8Inplace"; size_t outLen = 0; const char* str = p.readString8Inplace(&outLen); std::string bytes = hexString(str, sizeof(char) * (outLen + 1)); FUZZ_LOG() << "readString8Inplace: " << bytes << " size: " << outLen; }, PARCEL_READ_OPT_STATUS(android::String16, readString16), PARCEL_READ_WITH_STATUS(std::unique_ptr<android::String16>, readString16), PARCEL_READ_WITH_STATUS(std::optional<android::String16>, readString16), Loading @@ -150,8 +157,8 @@ std::vector<ParcelRead<::android::Parcel>> BINDER_PARCEL_READ_FUNCTIONS { FUZZ_LOG() << "about to readString16Inplace"; size_t outLen = 0; const char16_t* str = p.readString16Inplace(&outLen); FUZZ_LOG() << "readString16Inplace: " << hexString(str, sizeof(char16_t) * outLen) << " size: " << outLen; std::string bytes = hexString(str, sizeof(char16_t) * (outLen + 1)); FUZZ_LOG() << "readString16Inplace: " << bytes << " size: " << outLen; }, PARCEL_READ_WITH_STATUS(android::sp<android::IBinder>, readStrongBinder), PARCEL_READ_WITH_STATUS(android::sp<android::IBinder>, readNullableStrongBinder), Loading