We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 1d098a7 + 714adb8 commit 71db317Copy full SHA for 71db317
trusty/gatekeeper/trusty_gatekeeper.cpp
@@ -56,9 +56,9 @@ TrustyGateKeeperDevice::~TrustyGateKeeperDevice() {
56
57
SizedBuffer hidl_vec2sized_buffer(const hidl_vec<uint8_t>& vec) {
58
if (vec.size() == 0 || vec.size() > std::numeric_limits<uint32_t>::max()) return {};
59
- auto dummy = new uint8_t[vec.size()];
60
- std::copy(vec.begin(), vec.end(), dummy);
61
- return {dummy, static_cast<uint32_t>(vec.size())};
+ auto buffer = new uint8_t[vec.size()];
+ std::copy(vec.begin(), vec.end(), buffer);
+ return {buffer, static_cast<uint32_t>(vec.size())};
62
}
63
64
Return<void> TrustyGateKeeperDevice::enroll(uint32_t uid,
0 commit comments