Skip to content
Snippets Groups Projects
Commit 6209e17c authored by Ryan Pavlik's avatar Ryan Pavlik
Browse files

st/oxr: Make verification macros confirm that the handle is alive.

parent e5561b9b
No related branches found
Tags
No related merge requests found
...@@ -28,6 +28,13 @@ extern "C" { ...@@ -28,6 +28,13 @@ extern "C" {
"(" #thing " == %p)", \ "(" #thing " == %p)", \
(void*)new_thing); \ (void*)new_thing); \
} \ } \
if (new_thing->handle.state != OXR_HANDLE_STATE_LIVE) { \
return oxr_error(log, XR_ERROR_HANDLE_INVALID, \
" state == %s (" #thing " == %p)", \
oxr_handle_state_to_string( \
new_thing->handle.state), \
(void*)new_thing); \
} \
oxr_log_set_instance(log, lookup); \ oxr_log_set_instance(log, lookup); \
} while (0) } while (0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment