projects
/
platform
/
upstream
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9b67afb
)
asahi: Fix segfault with null drawbuffer
author
Alyssa Rosenzweig
<alyssa@rosenzweig.io>
Sat, 7 Jan 2023 20:25:49 +0000
(15:25 -0500)
committer
Marge Bot
<emma+marge@anholt.net>
Tue, 10 Jan 2023 00:17:12 +0000
(
00:17
+0000)
Fixes fbo-drawbuffers-none piglit.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20569>
src/gallium/drivers/asahi/agx_batch.c
patch
|
blob
|
history
diff --git
a/src/gallium/drivers/asahi/agx_batch.c
b/src/gallium/drivers/asahi/agx_batch.c
index
600b733
..
a786451
100644
(file)
--- a/
src/gallium/drivers/asahi/agx_batch.c
+++ b/
src/gallium/drivers/asahi/agx_batch.c
@@
-70,7
+70,8
@@
agx_batch_init(struct agx_context *ctx,
}
for (unsigned i = 0; i < key->nr_cbufs; ++i) {
- agx_batch_writes(batch, agx_resource(key->cbufs[i]->texture));
+ if (key->cbufs[i])
+ agx_batch_writes(batch, agx_resource(key->cbufs[i]->texture));
}
unsigned batch_idx = agx_batch_idx(batch);