We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 80c2e6d + 0d287d8 commit ab8f1f5Copy full SHA for ab8f1f5
src/memspaces/memspace_host_all.c
@@ -40,7 +40,10 @@ static umf_result_t umfMemspaceHostAllCreate(umf_memspace_handle_t *hMemspace) {
40
// object that can be present on multiple levels.
41
// Source: https://www.open-mpi.org/projects/hwloc/doc/hwloc-v2.10.0-letter.pdf
42
int nNodes = hwloc_get_nbobjs_by_type(topology, HWLOC_OBJ_NUMANODE);
43
- assert(nNodes != -1);
+ if (nNodes < 0) {
44
+ umf_ret = UMF_RESULT_ERROR_UNKNOWN;
45
+ goto err_topology_destroy;
46
+ }
47
48
size_t *nodeIds = umf_ba_global_alloc(nNodes * sizeof(size_t));
49
if (!nodeIds) {
0 commit comments