mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2024-12-28 18:46:18 +00:00
st/oxr: Improve verification of XrGraphicsBindingEGLMNDX
This commit is contained in:
parent
7ba4bee439
commit
f868f61a17
|
@ -593,9 +593,36 @@ XrResult
|
|||
oxr_verify_XrGraphicsBindingEGLMNDX(struct oxr_logger *log,
|
||||
const XrGraphicsBindingEGLMNDX *next)
|
||||
{
|
||||
// Here for internal error checking
|
||||
if (next->type != XR_TYPE_GRAPHICS_BINDING_EGL_MNDX) {
|
||||
return oxr_error(log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"Graphics binding has invalid type");
|
||||
return oxr_error(
|
||||
log, XR_ERROR_RUNTIME_FAILURE,
|
||||
"XrGraphicsBindingEGLMNDX::type is invalid '%i'",
|
||||
next->type);
|
||||
}
|
||||
|
||||
if (next->getProcAddress == NULL) {
|
||||
return oxr_error(
|
||||
log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"XrGraphicsBindingEGLMNDX::getProcAddress cannot be NULL");
|
||||
}
|
||||
|
||||
if (next->display == NULL) {
|
||||
return oxr_error(
|
||||
log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"XrGraphicsBindingEGLMNDX::display cannot be NULL");
|
||||
}
|
||||
|
||||
if (next->config == NULL) {
|
||||
return oxr_error(
|
||||
log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"XrGraphicsBindingEGLMNDX::config cannot be NULL");
|
||||
}
|
||||
|
||||
if (next->context == NULL) {
|
||||
return oxr_error(
|
||||
log, XR_ERROR_VALIDATION_FAILURE,
|
||||
"XrGraphicsBindingEGLMNDX::context cannot be NULL");
|
||||
}
|
||||
|
||||
return XR_SUCCESS;
|
||||
|
|
Loading…
Reference in a new issue