Validate enum range in RendererViewport::viewport_get_render_info
This commit is contained in:
parent
ba24e29334
commit
2200544141
|
@ -1012,6 +1012,7 @@ void RendererViewport::viewport_set_lod_threshold(RID p_viewport, float p_pixels
|
|||
}
|
||||
|
||||
int RendererViewport::viewport_get_render_info(RID p_viewport, RS::ViewportRenderInfoType p_type, RS::ViewportRenderInfo p_info) {
|
||||
ERR_FAIL_INDEX_V(p_type, RS::VIEWPORT_RENDER_INFO_TYPE_MAX, -1);
|
||||
ERR_FAIL_INDEX_V(p_info, RS::VIEWPORT_RENDER_INFO_MAX, -1);
|
||||
|
||||
Viewport *viewport = viewport_owner.get_or_null(p_viewport);
|
||||
|
|
Loading…
Reference in New Issue