SWDEV-351282 - Null check for desc.

Change-Id: I69d534b6f97442c69b66154476a2637e99c3df77
This commit is contained in:
Jaydeep Patel
2022-08-22 06:25:03 +00:00
committato da Jaydeepkumar Patel
parent ce5103ac97
commit cf57f20407
+3
Vedi File
@@ -1043,6 +1043,9 @@ hipError_t hipArray3DCreate(hipArray** array,
const HIP_ARRAY3D_DESCRIPTOR* pAllocateArray) {
HIP_INIT_API(hipArray3DCreate, array, pAllocateArray);
CHECK_STREAM_CAPTURE_SUPPORTED();
if (pAllocateArray == nullptr) {
HIP_RETURN(hipErrorInvalidValue);
}
HIP_RETURN(ihipArrayCreate(array, pAllocateArray, 0 /* numMipLevels */));
}