Merge RQ2A.210405.006 to stage-aosp-master - DO NOT MERGE
Merged-In: Ia79a4a3189a84591d35ab2303d2e20be77a21efa Change-Id: I4901e127f503239c93fd7d296867a2fc7bee8c58
This commit is contained in:
commit
5137d519a0
1 changed files with 5 additions and 1 deletions
|
@ -124,7 +124,11 @@ namespace implementation {
|
||||||
return Void();
|
return Void();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (source.offset + offset + source.size > sourceBase->getSize()) {
|
size_t totalSize = 0;
|
||||||
|
if (__builtin_add_overflow(source.offset, offset, &totalSize) ||
|
||||||
|
__builtin_add_overflow(totalSize, source.size, &totalSize) ||
|
||||||
|
totalSize > sourceBase->getSize()) {
|
||||||
|
android_errorWriteLog(0x534e4554, "176496160");
|
||||||
_hidl_cb(Status::ERROR_DRM_CANNOT_HANDLE, 0, "invalid buffer size");
|
_hidl_cb(Status::ERROR_DRM_CANNOT_HANDLE, 0, "invalid buffer size");
|
||||||
return Void();
|
return Void();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue