pocl_topology: actually cleanup behind ourselves
With we introduced a label for
a cleanup on exit in pocl_topology_detect_device_info, however, this
wasn't actually used (erroneously).
Do jump to it if hwloc_topology_load() fails, as the hwloc documentation
suggests the topology should get destroyed anyway in this case.
@@ -58,7 +58,7 @@ pocl_topology_detect_device_info(cl_device_id device)
if (ret == -1)
{
POCL_MSG_ERR ("Cannot load the topology.\n");
- return ret;
+ goto exit_destroy;
}
device->global_mem_size =
