Skip to content

Commit

Permalink
Merge pull request IntelPython#972 from IntelPython/fix-gh-965-issue-…
Browse files Browse the repository at this point in the history
…by-scan-tool

Handle the case when arraystruct->meminfo is null to close IntelPythongh-965
  • Loading branch information
oleksandr-pavlyk authored Mar 13, 2023
2 parents e8b71f0 + 37e5f4a commit 4c18ebd
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions numba_dpex/core/runtime/_dpexrt_python.c
Original file line number Diff line number Diff line change
Expand Up @@ -959,6 +959,13 @@ DPEXRT_sycl_usm_ndarray_to_python_acqref(arystruct_t *arystruct,
}
Py_DECREF(args);
}
else {
PyErr_Format(PyExc_ValueError,
"In 'DPEXRT_sycl_usm_ndarray_to_python_acqref', "
"failed to create a new MemInfoObject object since "
"meminfo field was null");
return MOD_ERROR_VAL;
}

shape = arystruct->shape_and_strides;

Expand Down

0 comments on commit 4c18ebd

Please sign in to comment.