SWDEV-330661 - devicePointer null checking.
Change-Id: I3366031954330143109d0a79e86fd0e0ec996f01
[ROCm/clr commit: ff78c439ef]
这个提交包含在:
1 父节点
83e2a8a892
当前提交
583aa7f008
1 个文件已更改
+5
@@ -2608,9 +2608,14 @@ hipError_t hipIpcCloseMemHandle(void* dev_ptr) {
|
||||
HIP_RETURN(hipSuccess);
|
||||
}
|
||||
|
||||
|
||||
hipError_t hipHostGetDevicePointer(void** devicePointer, void* hostPointer, unsigned flags) {
|
||||
HIP_INIT_API(hipHostGetDevicePointer, devicePointer, hostPointer, flags);
|
||||
|
||||
if (devicePointer == nullptr) {
|
||||
HIP_RETURN(hipErrorInvalidValue);
|
||||
}
|
||||
|
||||
size_t offset = 0;
|
||||
|
||||
amd::Memory* memObj = getMemoryObject(hostPointer, offset);
|
||||
|
||||
在新工单中引用
屏蔽一个用户