mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-19 16:24:18 +08:00
fix: fix potential integer overflow in CommandListCoreFamily getInputBufferSize
Related-To: GSD-4137 Signed-off-by: Wenju He <wenju.he@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
489ef2a310
commit
b0b82171ab
@@ -2267,9 +2267,9 @@ inline uint64_t CommandListCoreFamily<gfxCoreFamily>::getInputBufferSize(NEO::Im
|
||||
return bufferRowPitch;
|
||||
case NEO::ImageType::image2D:
|
||||
case NEO::ImageType::image2DArray:
|
||||
return bufferRowPitch * region->height;
|
||||
return static_cast<uint64_t>(bufferRowPitch) * region->height;
|
||||
case NEO::ImageType::image3D:
|
||||
return bufferSlicePitch * region->depth;
|
||||
return static_cast<uint64_t>(bufferSlicePitch) * region->depth;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user