The open source OpenXR runtime

ipc: return NULL in ipc_client_system_create if call to systep properties fails

Part-of: <https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2140>

+5 -1
+5 -1
src/xrt/ipc/client/ipc_client_system.c
··· 136 136 { 137 137 struct ipc_client_system *icsys = U_TYPED_CALLOC(struct ipc_client_system); 138 138 xrt_result_t xret = ipc_call_system_get_properties(ipc_c, &icsys->base.properties); 139 - assert(xret == XRT_SUCCESS); 139 + if (xret != XRT_SUCCESS) { 140 + free(icsys); 141 + return NULL; 142 + } 143 + 140 144 icsys->base.create_session = ipc_client_system_create_session; 141 145 icsys->base.destroy = ipc_client_system_destroy; 142 146 icsys->ipc_c = ipc_c;