Mesa (main): lavapipe: handle null vertex buffers more gracefully
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Tue Jul 6 16:27:04 UTC 2021
Module: Mesa
Branch: main
Commit: 95777ab419c8bf1e064c278bc87dc2322425b852
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=95777ab419c8bf1e064c278bc87dc2322425b852
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Mon Jul 5 18:01:16 2021 -0400
lavapipe: handle null vertex buffers more gracefully
this should propagate down to be handled correctly in llvmpipe
Reviewed-by: Dave Airlie <airlied at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11723>
---
src/gallium/frontends/lavapipe/lvp_execute.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/frontends/lavapipe/lvp_execute.c b/src/gallium/frontends/lavapipe/lvp_execute.c
index 020c6394d99..d0cdcbd6c25 100644
--- a/src/gallium/frontends/lavapipe/lvp_execute.c
+++ b/src/gallium/frontends/lavapipe/lvp_execute.c
@@ -739,7 +739,7 @@ static void handle_vertex_buffers(struct lvp_cmd_buffer_entry *cmd,
int idx = i + vcb->first;
state->vb[idx].buffer_offset = vcb->offsets[i];
- state->vb[idx].buffer.resource = vcb->buffers[i]->bo;
+ state->vb[idx].buffer.resource = vcb->buffers[i] ? vcb->buffers[i]->bo : NULL;
if (vcb->strides) {
state->vb[idx].stride = vcb->strides[i];
More information about the mesa-commit
mailing list