projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
db0f9e7
)
mesa: Guard against null pointer deref in fbo validation
author
Fabian Bieler
<der.fabe@gmx.net>
Tue, 5 Apr 2011 13:51:01 +0000
(07:51 -0600)
committer
Brian Paul
<brianp@vmware.com>
Tue, 5 Apr 2011 13:51:01 +0000
(07:51 -0600)
This matches the behaviour below when numSamples is compared.
At least with the gallium state tracker this can actually occur if st_render_texture fails.
Signed-off-by: Brian Paul <brianp@vmware.com>
src/mesa/main/fbobject.c
patch
|
blob
|
history
diff --git
a/src/mesa/main/fbobject.c
b/src/mesa/main/fbobject.c
index f0065ad06a9e77d5a2c65651b57d7fa0023e3cc7..eb1fef51427d47c7007a12198de14e73d18e2397 100644
(file)
--- a/
src/mesa/main/fbobject.c
+++ b/
src/mesa/main/fbobject.c
@@
-746,7
+746,7
@@
_mesa_test_framebuffer_completeness(struct gl_context *ctx,
continue;
}
- if (numSamples < 0) {
+ if (
att->Renderbuffer &&
numSamples < 0) {
/* first buffer */
numSamples = att->Renderbuffer->NumSamples;
}