st/oxr: projection layer swapchain NULL check

This commit is contained in:
Christoph Haag 2020-08-24 10:17:07 +02:00
parent 1914a2ee93
commit 5a854fc806

View file

@ -755,6 +755,15 @@ verify_projection_layer(struct xrt_compositor *xc,
layer_index, i, p->x, p->y, p->z);
}
if (view->subImage.swapchain == XR_NULL_HANDLE) {
printf("foo\n");
return oxr_error(
log, XR_ERROR_HANDLE_INVALID,
"(frameEndInfo->layers[%u]->views[%i]->subImage."
"swapchain is XR_NULL_HANDLE",
layer_index, i);
}
struct oxr_swapchain *sc = XRT_CAST_OXR_HANDLE_TO_PTR(
struct oxr_swapchain *, view->subImage.swapchain);